Why is the following loop not ending at 15 4? style=”color:rgb(45,54,57);”>What is the output of the following loop? int total = 25; for (int number = 1; number <= (total / 2); number++) { total = total – number; System.out.println(total + " " + number);
Why is the following loop not ending at 15 4?
style=”color:rgb(45,54,57);”>What is the output of the following loop?
int total = 25;
for (int number = 1; number <= (total / 2); number++) {
total = total – number;
System.out.println(total + ” ” + number);