Which code segment results in "true" being returned if a number is even? Replace "MISSING CONDITION" with the correct code segment.
AP CSP Unit 7: Parameters, Returns, and Libraries

Flashcard
•
Computers
•
9th - 12th Grade
•
Hard
Quizizz Content
FREE Resource
Student preview

15 questions
Show all answers
1.
FLASHCARD QUESTION
Front
Back
num % 2 == 0;
2.
FLASHCARD QUESTION
Front
What will be printed to the console after this program runs? Options: [2, 5, 3, 1, 6], [0, 3, 6, -1, 9], [-1, 2, 6, -2, 8], [5, 2, 6, 3, 9]
Back
[0, 3, 6, -1, 9]
3.
FLASHCARD QUESTION
Front
Which function calls would provide the most helpful test of this function? Remember: With tests, you are attempting to figure out all the possible ways the function could be broken. function findMin(num1, num2){ if(num1 < num2){ return num1; } else { return num2; }}
Back
findMin(-1,1), findMin(1,-1), findMin(1,1)
4.
FLASHCARD QUESTION
Front
listAverage() returns the average number in a list. Which of these functions does this correctly?
Back
5.
FLASHCARD QUESTION
Front
Which of the following is NOT true about procedural abstraction? Procedural abstraction improves code readability, Procedural abstraction manages complexity by allowing for code reuse, Procedural abstraction improves the speed at which a program executes, Procedural abstraction allows a solution to a large problem to be based on the solution of smaller subproblems
Back
Procedural abstraction improves the speed at which a program executes
6.
FLASHCARD QUESTION
Front
Where should return false; be written in the code?
Back
OPTION C
7.
FLASHCARD QUESTION
Front
This function finds the minimum number in a list. What should
Back
min = numList[i];
Create a free account and access millions of resources
Similar Resources on Quizizz
12 questions
BJC AP CSP Unit 3 Exam Review (In-Class)

Flashcard
•
9th - 12th Grade
15 questions
AP Flashcard #1 Review

Flashcard
•
9th - 12th Grade
12 questions
BJC AP CSP Unit 3 Exam Review (In-Class)

Flashcard
•
9th - 12th Grade
15 questions
APCSP - Unit 1 Review

Flashcard
•
10th - 12th Grade
21 questions
AP CSP Unit 7: Parameters, Returns, and Libraries

Flashcard
•
9th - 12th Grade
9 questions
App Lab Controls

Flashcard
•
9th - 12th Grade
12 questions
CSP Unit 1 - Lessons 1-6 Vocab Review

Flashcard
•
9th - 12th Grade
10 questions
Arrays

Flashcard
•
10th - 12th Grade
Popular Resources on Quizizz
15 questions
Character Analysis

Quiz
•
4th Grade
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
10 questions
American Flag

Quiz
•
1st - 2nd Grade
20 questions
Reading Comprehension

Quiz
•
5th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
18 questions
Full S.T.E.A.M. Ahead Summer Academy Pre-Test 24-25

Quiz
•
5th Grade
14 questions
Misplaced and Dangling Modifiers

Quiz
•
6th - 8th Grade
Discover more resources for Computers
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
20 questions
Taxes

Quiz
•
9th - 12th Grade
17 questions
Parts of Speech

Quiz
•
7th - 12th Grade
20 questions
Chapter 3 - Making a Good Impression

Quiz
•
9th - 12th Grade
20 questions
Inequalities Graphing

Quiz
•
9th - 12th Grade
10 questions
Identifying equations

Quiz
•
KG - University