--Originally published at Just A Turtle Coding.
So here’s another use of the for loop, you can use it to calculate the factorial of a number.
First you have to declare your variable which will be storing the count, and the one which will be storing the total. After that you just multiply and add inside the for loop.
Another example done by turtle :D