
AP CSP: Checkpoint 2 (Graded - Allowed 2 Attempts)
Quiz by Praise
Tag the questions with any skills you have. Your dashboard will track each student's mastery of each skill.
Consider the following code segment, which uses the variables r, s, and t.Â

Which of the following is a true statement about program documentation?
The algorithm below is used to simulate the results of flipping a coin 4 times. Consider the goal of determining whether the simulation resulted in an equal number of heads and tails.
Step 1 : Initialize the variables heads_counter and flip_counter to 0.
Step 2 : A variable coin_flip is randomly assigned a value of either 0 or 1. If coin_flip has the value 0, the coin flip result is heads, so heads_counter is incremented by 1.
Step 3 : Increment the value of flip_counter by 1.
Step 4 : Repeat steps 2 and 3 until flip_counter equals 4.
Following execution of the algorithm, which of the following expressions indicates that the simulation resulted in an equal number of heads and tails?

An algorithm has been developed to compute the sum of all the elements in a list of integers. Which of the following programming structures must be added to the existing algorithm so that the new algorithm computes the sum of only the even integers in the list?
An algorithm has been designed to display each element in a list of names. Which programming structure is necessary to ensure each name in the list is displayed, one after the other?
A program requires steps to be executed in a specific order: first reading input, then processing the data, and finally displaying the result. Which programming structure is responsible for ensuring that these steps happen in the correct order?
Which of the following scenarios requires the use of iteration?
An algorithm needs to execute the following steps in sequence: initialize a counter, set the counter to zero, then start adding values to the counter from a list. Which of the following terms best describes the need to follow these steps in a specific order?
In a program that reads a list of items and then sorts them alphabetically before displaying them, what role does sequencing play?
Which of the following activities poses the greatest personal cybersecurity risk?
A programmer is writing a program that is intended to be able to process large amounts of data. Which of the following considerations is LEAST likely to affect the ability of the program to process larger data sets?
Which of the following is LEAST likely to indicate a phishing attack?
Which of the following is considered an unethical use of computer resources?
Which of the following statements are true about using a high-level programming language instead of a lower-level language?
I. Programs written in a high-level language are generally easier for people to read than programs written in a low-level language.
II. A high-level language provides programmers with more abstractions than a low-level language.
III. Programs written in a high-level language are generally easier to debug than programs written in a low-level language.
What is displayed as a result of executing the algorithm in the flowchart?

A city government is attempting to reduce the digital divide between groups with differing access to computing and the Internet. Which of the following activities is LEAST likely to be effective in this purpose?
SELECT TWO ANSWERS
Which of the following Boolean expressions are equivalent to the expression num ≥ 15 ?
Which of the following are benefits of using well-named variables in a computer program?
Select two answers.
A school library allows students to borrow laptops. A computer program is used to count the number of times a particular laptop has been borrowed from the library (borrows) and the number of times the same laptop has been returned to the library (returns). Which of the following indicate that a particular laptop is not currently borrowed?
Select two answers