
AP CSP: Semester 1 Final Exam
Quiz by Praise
Tag the questions with any skills you have. Your dashboard will track each student's mastery of each skill.
After the following code runs, what is the value of z?

What is displayed as a result of running this program?

The following program asks the user for a multiple of 4 until they correctly input a multiple of 4. What code should be added to lines 3-4 so that there is not an infinite loop?

Which of the following is NOT a reason why programmers use comments?
What will print to the console when the following program runs?

What would be the radius, in pixels, of the circle output from the following code?

If the user enters the number ‘5’, what is printed to the console when this program runs?

Given the following segment of code, what will the output be?
DISPLAY(3 * 2 + 4 MOD 5)
Given the following, what will the output be?
DISPLAY(4 + 6 / 5)
A student is trying to prompt a user to enter number and then add them to a variable called sumEven, but only if the user enters an even number. For example, if the user enters 4, 5, 6 then sumEven will equal 10.
Which of the following operators will be most helpful to help accomplish this task?
Given the following code
a ← 8
b ← 3
ans ← (a + 3 * b) MOD (c + 4)
Which of the following values for c would result in ans being set to 1
How many possible values does a boolean have?
Which of the following Boolean expressions is equivalent to the expression:
a AND (b OR c)
What is displayed as a result of executing the following program?

After the following code runs, what is the value of number?

After the following code runs, what is the value of count?
