Are you taking CLEP classes? Try clep.ai
| preferred AP College board partner for AP classes
AP Computer Science A/Unit 4: Iteration
Start Practice TestPractice Test
About Exam
easy Solved by 3 students

Decrementing For Loop

Mark
< Prev
Next >

What is printed when the following code segment is executed?

public class ReverseFor {
    public static void main(String[] args) {
        for (int i = 3; i >= 1; i--) {
            System.out.print(i);
        }
    }
}
A

321

B

3 2 1

C

123

D

Compilation Error

Hint
Did You Know?
Explain Why
Explain All Answers
Check Answer
Show Correct Answer
Report Question

Question Leaderboard

Rank
User
Correct Count
Attempt Count
Total Time
Score
#1hitrishabhatia22 0m 00s 200
#2busemagngr11 0m 26s 74
#3meromaroseif12 1m 05s 25
Items per page:
10
1 – 3 of 3

AI Tutor

How can I help?

APFIVE © 2020.
Email: apfive@apfive.org|Privacy Policy|