AP CSP Conditionals
Quiz
•
Computers
•
9th - 12th Grade
•
Practice Problem
•
Medium
Alicia Wade
Used 161+ times
FREE Resource
About this resource
This quiz focuses on boolean logic and conditional statements in computer programming, specifically targeting AP Computer Science Principles concepts at the high school level (grades 9-12). The questions systematically assess students' understanding of logical operators including AND (&&), OR (||), and NOT (!), as well as comparison operators for equality and relational comparisons. Students must demonstrate mastery of operator precedence, the ability to evaluate complex nested boolean expressions, and understanding of how conditional statements control program flow. The core reasoning skills required include logical thinking, step-by-step expression evaluation, and comprehension of how multiple conditions combine to produce true or false outcomes. Students need to understand variable assignment, string and numeric comparisons, and the syntax conventions used in programming languages for conditional constructs. Created by Alicia Wade, a Computer Science teacher in the US who teaches grades 9-12. This quiz serves as an excellent formative assessment tool for reinforcing fundamental programming concepts before students tackle more complex algorithmic thinking challenges. Teachers can deploy this as a warm-up activity to activate prior knowledge, use it for guided practice during direct instruction, or assign it as homework to solidify understanding of boolean operations. The systematic progression from simple comparisons to complex nested expressions makes it ideal for differentiated instruction and helps identify specific areas where students need additional support. This assessment directly supports CSTA K-12 Computer Science Standards, particularly 3A-AP-15 (justifying the selection of specific control structures) and 3A-AP-10 (using variables within a program), while building foundational skills essential for success on the AP Computer Science Principles exam.
See more
Student preview

13 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized with the values shown.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
(age > 10) && (age < 20)
true
false
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized as shown below.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
!(age > 10)
true
false
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized as shown below.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
(day == "Tuesday") || (age < 12)
true
false
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized as shown below.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
!((age == 16) || (day == "Monday"))
true
false
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized as shown below.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
!((age == 16) && !(day == "Monday"))
true
false
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized as shown below.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
((age == 16) && (day == "Monday")) && (day == "Tuesday")
true
false
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assume that the two variables age and day have been initialized as shown below.
var age = 16;
var day = "Monday";
Determine if the following statement evaluates to true or false.
((age == 16) && (day == "Monday")) || (day == "Tuesday")
true
false
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade