Comp Sci Unit 2 #9

Quiz
•
Computers
•
11th Grade
•
Easy
Nick Nessralla
Used 14+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
The following spinner is used in a game. The region labeled "blue" represents 1/4 of the spinner. The regions labeled "orange" and "purple" are equal in size.
Which of the following code segments can be used to simulate the behavior of the spinner?
Select two answers.
2.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
In a certain game, the integer variable bonus is assigned a value based on the value of the integer variable score.
If score is greater than 100, bonus is assigned a value that is 10 times score.
If score is between 50 and 100 inclusive, bonus is assigned the value of score.
If score is less than 50, bonus is assigned a value of 0.
Which of the following code segments assigns bonus correctly for all possible integer values of score ?
Select two answers.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Ticket prices for a science museum are shown in the following table.
A programmer is creating an algorithm to display the cost of a ticket based on the information in the table. The programmer uses the integer variable age for the age of the ticket recipient. The Boolean variable includesTour is true when the ticket is for a guided tour and is false when the ticket is for general admission.
Which of the following code segments correctly displays the cost of a ticket?
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Consider the code segment below.
If the variables onTime and absent both have the value false, what is displayed as a result of running the code segment?
Is anyone there?
Better late than never.
Hello. Is anyone there?
Hello. Better late than never.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Consider the following code segment with integer variables x and y.
If x has a value of 7 and y has a value of 20, what is displayed as a result of executing the code segment?
ONE
TWO
THREE
FOUR
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In the program below, the initial value of x is 5 and the initial value of y is 10.
What is displayed as a result of running the program?
Foxtrot
Hotel
November
Yankee
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Directions: The question or incomplete statement below is followed by four suggested answers or completions. Select the one that is best in each case.
A student wrote the procedure below, which is intended to ask whether a user wants to keep playing a game. The procedure does not work as intended.
Which of the following best describes the result of running the procedure?
The procedure returns true when the user inputs the value "y" and returns false otherwise.
The procedure returns true when the user inputs the value "n" and returns false otherwise.
The procedure returns true no matter what the input value is.
The procedure returns false no matter what the input value is.
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
If-Statement and Relational Operators Quiz

Quiz
•
6th Grade - University
9 questions
C# Variables and Data Types

Quiz
•
8th Grade - University
15 questions
Code.org Unit 5 Lesson 15 Assessment

Quiz
•
9th - 12th Grade
10 questions
Code.org Discoveries

Quiz
•
9th - 11th Grade
10 questions
AP Computer Science Principles Unit 3 Review

Quiz
•
9th - 12th Grade
10 questions
Unit 1 Review AP CSP

Quiz
•
9th - 12th Grade
10 questions
COMP SCI Unit 2 #7

Quiz
•
11th Grade
15 questions
Unit 8 Javascript Quiz

Quiz
•
9th - 12th Grade
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
20 questions
Digital Citizenship

Quiz
•
8th - 12th Grade
35 questions
Computer Baseline Examination 2025-26

Quiz
•
9th - 12th Grade
13 questions
Problem Solving Process

Quiz
•
9th - 12th Grade
10 questions
Understanding Algorithms with Pseudocode and Flowcharts

Interactive video
•
9th - 12th Grade
19 questions
AP CSP Unit 1 Review (code.org)

Quiz
•
10th - 12th Grade