top of page
APCSAaday.com

for (int n = 25; n >= 0; n/=2)
System.out.println(n);
When the segment is executed, how many passes through the for loop will there be?
A) Fewer than 5
B) Between 5 and 12, inclusive
C) Between 13 and 25, inclusive
D) Between 26 and 100, inclusive
E) More than 100
What is the correct answer?
A
B
C
D
Related Posts
Comments
Share Your ThoughtsBe the first to write a comment.
bottom of page