Search the courses, subjects, tracks, games and features, or jump straight to a page.
2 cards from this section. Quick, good the night before a test.
What does an if statement do in programming?
Think about decision making in code.
How do you create a for loop to print numbers from 1 to 5?
Look at the range function in Python.
What statement would determine if a student has passed based on marks?
Think of the threshold to pass.
True or False: A for loop can execute indefinitely.
Consider the conditions that terminate loops.
Write a program that calculates the factorial of a number using a loop.
Consider how multiplication might repeat as you go through numbers.
Create a pattern of numbers for a pyramid shape using loops.
Think about how to center the asterisks with spaces.
5 more questions in this section. Enroll free to practise them all.
Enroll free