using System;
public class ForLoopCounter
{
public static void Main()
int endNumber = 100;
// For loops usually have 3 components in the "for" statement.
// (1) "int i = 0" = this is the starting point of the for loop. You can use any variable name and any starting position. "i" is a common variable name for for loops.
// (2a) "i <= endNumber" - this part states "WHILE the value of variable "i" is less than OR equal to the value of variable "endNumber", execute this loop.
// (2b) The loop will run until "i" reaches the value of "endNumber".
// (3a) "i++" - This tells the loop to increase the value of "i" by 1 on every loop iteration.
// (3b) In order to avoid an infinite loop, this value should change on every iteration - either by going DOWN or UP.
for (int i = 0; i <= endNumber; i++)
Console.WriteLine(i);
}