New course! Every coder should learn Generative AI!
Try a free lesson0
The program isn't giving correct output though it has zero errors.
2 Answers
+ 3
Line 8:
Mutiply <factorial> by <i> rather than 1, in the for-loop.
factorial *= i;
+ 1
Ipang Thank you bro!!!
How silly this mistake was. 😑😶