For which values of the integer value will the following code-03280
For which values of the integer _value will the following code becomes an infinite loop?<br>int number=1;<br>while (true) {<br>cout << number;<br>if (number == 3) break;<br>number += integer_value; }
This multiple choice question (MCQ) is related to the book/course vu cs201 Introduction to Programming. It can also be found in vu cs201 Mid Term - Quiz No.19.
For which values of the integer _value will the following code becomes an infinite loop?
int number=1;
while (true) {
cout << number;
if (number == 3) break;
number += integer_value; }
int number=1;
while (true) {
cout << number;
if (number == 3) break;
number += integer_value; }
any number other than 1 or 2
only 0
only 1
only 2