16.8k views
4 votes
How many times will the following loop execute?

int x = 0;
do {
x++;
cout << x << endl;
}while(x < 5)
Answers:
a. - 5 times
b. - 4 times
c. - It doesn't
d. - Infinite times
e. - 6 times

User Tim Dams
by
7.5k points

1 Answer

7 votes

Answer:

Explanation:

The loop will run an infinite number of times

User Kostas Livieratos
by
8.3k points