Loops
For Loop:
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10
5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25
8, 7, 6, 5, 4, 3, 2, 1, 0
0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20
While Loop:
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10
*
* *
* * *
* * * *
* * * * *
*
* *
* * *
* * * *
* * * * *
1 2 3 4 5 6 7 8
2 3 4 5 6 7 8 1
3 4 5 6 7 8 1 2
4 5 6 7 8 1 2 3
5 6 7 8 1 2 3 4
6 7 8 1 2 3 4 5
7 8 1 2 3 4 5 6
8 1 2 3 4 5 6 7