129k views
3 votes
What is the final value of x (after this code has executed)?

int x = 0;

for (x = 0; x < 200; x++)

{

System.out.println(x);

}

1 Answer

1 vote

Answer:

199

Step-by-step explanation:

i starts at 0. One more than 0 is one. Until you get 199.

The computer is counting as seen below:

0

1

2

....

199

User Michal S
by
6.6k points