If I had the following while loop:
What would the value of count after the loop is executed with the following data keyed in:Code:int count = 0; cin >> value; while (value < 0 && count < 5) { cout <<"Value must be non-negative;" <<"enter value again. " <<endl; cin >>value; count++; }
-1
-2
-1
0
3
--Would it be 3, b/c when it enters 0 then it jumps out?
thanks