CJCoding With Joseph
15free / daySign inCreate account
โ† Back to Question List
C++ Code Walkthrough #4

For Loop with Continue

easyLoops

๐Ÿ“„ Code

Read carefully โ€” what does this print?
1#include <iostream>
2using namespace std;
3 
4int main() {
5 for (int i = 0; i < 6; i++) {
6 if (i % 2 == 0) {
7 continue;
8 }
9 cout << i << " ";
10 }
11 cout << endl;
12 return 0;
13}

๐ŸŽฏ Your Answer