Need a little push in the right direction. Lesson 22 Counting Down. Just a hint please. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Need a little push in the right direction. Lesson 22 Counting Down. Just a hint please.

#include <iostream> using namespace std; int main() { int n; int x; cin >> n; //your code goes here while (n >= 1) { cout << n << endl; x = n % 5; if (x = 0) { cout << "beep" << endl; } n--; } return 0; }

27th Aug 2021, 6:11 PM
Pie Don
Pie Don - avatar
1 Answer
0
Ahh crap, thank you. that one always gets me.
27th Aug 2021, 6:20 PM
Pie Don
Pie Don - avatar