asked 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

asked
User Tim Dams
by
7.5k points

1 Answer

7 votes

Answer:

Explanation:

The loop will run an infinite number of times

Welcome to Qamnty — a place to ask, share, and grow together. Join our community and get real answers from real people.