1. i is set to 0
2. tests to see if it should execute the body: as 0 is less than or equal to 5, it continues
3. calls cout << name[0]
4. then it increments i by 1 to 1
5. and goes back to step 2; this time i is 1, so it's still less than or equal to 5, it continues
6. calls cout << name[1]
7. then it increments i by 1 to 2
8. and goes back to step 2; this time i is 2, so it's still less than or equal to 5, it continues
9. calls cout << name[2]
10. then it increments i by 1 to 3
11. and goes back to step 2; this time i is 3, so it's still less than or equal to 5, it continues
12. calls cout << name[3]
13. then it increments i by 1 to 4
14. and goes back to step 2; this time i is 4, so it's still less than or equal to 5, it continues
15. calls cout << name[4]
16. then it increments i by 1 to 5
17. and goes back to step 2; this time i is 5, so it's still less than or equal to 5, it continues
18. calls cout << name[4]
19. then it increments i by 1 to 6
20. and goes back to step 2; this time i is 6, so it's no longer less than or equal to 5, so the loop breaks!