<
RHD
/>
Home
Blog
Quiz
Resources
About
Contact
Enlist
// guest
▾
Login
Request Account
[ light ]
// Control Flow
Control Flow Quiz
// question 1 of 10
What is the result of 5 > 2?
False
5
True
// question 2 of 10
What does else do?
Stops the program
Runs code if condition is False
Creates variables
// question 3 of 10
What is printed? for i in range(2): print(""**"")?
2 lines of **
4 stars
1 line of **
// question 4 of 10
What is printed? x=1 while x<=3: print(x) x+=1?
0 1 2 3
1 2
1 2 3
// question 5 of 10
What is printed? if 4 < 5 and 2 > 3: print(""A"")?
A
Nothing
Error
// question 6 of 10
What are star patterns usually built with?
Only while
Only if
Nested loops
// question 7 of 10
What is printed? while False: print(""A"")?
A
Error
Nothing
// question 8 of 10
What does for do?
Repeats code for items
Stops program
Checks conditions
// question 9 of 10
What is printed? for i in range(3): print(i+1)?
1 2 3 4
0 1 2
1 2 3
// question 10 of 10
What is printed? if not True: print(""Yes"")?
Nothing
Yes
Error
Submit Answers →