A robot takes five steps and calls out each one, 1 to 5, one per line. The counting and the stopping are written already — only the calling out is missing.
1 2 3 4 5
#include <iostream>
using namespace std;
int main() {
int steps = 0;
while (steps < 5) {
steps++;
// your code here: show which step it is on now
}
return 0;
}
Run tries the examples. When they look right, Submit.