In the following expression, the variable truckWeight has the value 70000 and the variable weightLimit has the value 80000.
truckWeight < weightLimit
What value does the expression evaluate to?
AP CSP 3.5 Boolean Expressions Pt. 1
Quiz
•
Computers
•
9th - 12th Grade
•
Medium
Herman Galioulline
Used 27+ times
FREE Resource
6 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
In the following expression, the variable truckWeight has the value 70000 and the variable weightLimit has the value 80000.
truckWeight < weightLimit
What value does the expression evaluate to?
70000
80000
true
false
2.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
To qualify for a particular scholarship, a student must have an overall grade point average of 3.0 or above and must have a science grade point average of over 3.2. Let overallGPA represent a student’s overall grade point average and let scienceGPA represent the student’s science grade point average. Which of the following expressions evaluates to true if the student is eligible for the scholarship and evaluates to false otherwise?
(overallGPA > 3.0) AND (scienceGPA > 3.2)
(overallGPA > 3.0) AND (scienceGPA ≥ 3.2)
(overallGPA ≥ 3.0) AND (scienceGPA > 3.2)
(overallGPA ≥ 3.0) AND (scienceGPA ≥ 3.2)
3.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
Let n be an integer value. Which of the following expressions evaluates to true if and only if n is a two-digit integer (i.e., in the range from 10 to 99, inclusive)?
n = (n MOD 100)
(n ≥ 10) AND (n < 100)
(n < 10) AND (n ≥ 100)
(n > 10) AND (n < 99)
4.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
To attend a particular camp, a student must be either at least 13 years old or in grade 9 or higher, but must not yet be 18 years old. Let age represent a student’s age and let grade represent the student’s grade level. Which of the following expressions evaluates to true if the student is eligible to attend the camp and evaluates to false otherwise?
((age ≥ 13) OR (grade ≥ 9)) AND (age ≤ 18)
((age ≥ 13) OR (grade ≥ 9)) AND (age < 18)
((age ≥ 13) OR (grade ≥ 9)) OR (age ≤ 18)
((age ≥ 13) OR (grade ≥ 9)) OR (age < 18)
5.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
The following code segment is used to determine whether a customer is eligible for a discount on a movie ticket.
val1 ← (NOT (category = "new")) OR (age ≥ 65)
val2 ← (category = "new") AND (age < 12)
If category is "new" and age is 20, what are the values of val1 and val2 as a result of executing the code segment?
val1 = true, val2 = true
val1 = true, val2 = false
val1 = false, val2 = true
val1 = false, val2 = false
6.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
true true true
false false false
true false true
false false true
10 questions
AP CSP Review
Quiz
•
9th - 12th Grade
10 questions
Resume Do's and Don'ts
Quiz
•
9th - 12th Grade
8 questions
AP Computer Science Principles Unit 4 Review
Quiz
•
9th - 12th Grade
10 questions
AP CSP Boolean Logic 3
Quiz
•
9th - 12th Grade
10 questions
Estructura Condicional If en Python
Quiz
•
10th Grade
10 questions
Comp Sci Unit 2 #8
Quiz
•
11th Grade
10 questions
AP CSP-Review Session 1 MCQ Quiz
Quiz
•
10th Grade
10 questions
Comp Sci Quiz #6
Quiz
•
11th Grade
10 questions
Chains by Laurie Halse Anderson Chapters 1-3 Quiz
Quiz
•
6th Grade
20 questions
math review
Quiz
•
4th Grade
15 questions
Character Analysis
Quiz
•
4th Grade
12 questions
Multiplying Fractions
Quiz
•
6th Grade
30 questions
Biology Regents Review #1
Quiz
•
9th Grade
20 questions
Reading Comprehension
Quiz
•
5th Grade
20 questions
Types of Credit
Quiz
•
9th - 12th Grade
50 questions
Biology Regents Review: Structure & Function
Quiz
•
9th - 12th Grade
30 questions
Biology Regents Review #1
Quiz
•
9th Grade
20 questions
Types of Credit
Quiz
•
9th - 12th Grade
50 questions
Biology Regents Review: Structure & Function
Quiz
•
9th - 12th Grade
20 questions
Taxes
Quiz
•
9th - 12th Grade
20 questions
Chapter 3 - Making a Good Impression
Quiz
•
9th - 12th Grade
14 questions
Attributes of Linear Functions
Quiz
•
9th - 12th Grade
10 questions
Identifying equations
Quiz
•
KG - University
50 questions
Biology Regents Review 2: Ecology
Quiz
•
9th - 12th Grade