Computer Science Review

Quiz
•
Computers
•
9th - 12th Grade
•
Hard
Charles Martinez
FREE Resource
9 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
A large office building has an elevator that carries occupants between any of the building's 10 floors. The basement is referred to as "Level 0" while the topmost floor is "Level 9." The software for the elevator uses a variable, called level, to track the floor number of the elevator's current position. When a person presses a button requesting the elevator to rise to a higher floor, the above code is executed.
What is displayed if the elevator is currently on the 7th floor (level = 7) and the person on the elevator presses a button that says to go up 3 floors (floors = 3)?
Level 7 Level 8 Level 9
Level 8 Level 9 Cannot go up. Level 9
Level 8 Level 9 Level 10
Cannot go up.
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Consider the above code segments designed to find the area of a triangle (A = 1/2 bh).
Which of the following statements about the above programs is true?
Both programs will work as intended, but Program B is more readable.
Program A will work as intended, but Program B will not work as intended.
Program B will work as intended, but Program A will not work as intended.
Neither program will work as intended.
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Given the above code segment, what would be displayed if age were initialized with a value of 18?
group 1
group 2
group 1 group 2
Nothing will be displayed
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which of the following would be the most appropriate name for a variable?
variable1
t
amountOfTimeRemainingInTheGame
time_left
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
While developing a program, you find a similar project that someone has created and posted online. It contains a number of elements (e.g., images, music, code segments, etc.) that you would like to integrate into your own project. Under what conditions may you reuse these elements in your work?
You may never reuse someone else’s work.
You may reuse any elements that are posted publicly online as long as credit is given to their creator.
You may only reuse elements for which the original owner has granted a license to reuse, such as the Creative Commons Share Alike license.
You may always reuse anything that is posted publicly or privately online.
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Consider the above code.
Assuming that before this code is run, x = 1. What would be displayed at the end?
210
16
8
1
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What condition will make the above an infinite loop?
y = -108
y≠-3
y ≥ 8
y < -53
8.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Consider the above code segment.
Which of the following best describes the result of running the code segment?
The number 0 is displayed.
The number 4 is displayed.
The number 10 is displayed.
Nothing is displayed; the program results in an infinite loop.
9.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
The volume of a rectangular prism is calculated by multiplying its length, width and height. What could be substituted into the section of the code marked < missing code > that would accurately calculate the volume based on the user input of l, w and h?
l x w x h
l * w * h
l(w)(h)
l / w / h
Similar Resources on Wayground
12 questions
Small Basic Quiz

Quiz
•
7th - 9th Grade
13 questions
2.5 Translators & Facilities - OCR GCSE Computer Science

Quiz
•
7th - 12th Grade
14 questions
GCSE Computing Low & High Level Languages/IDE's

Quiz
•
10th - 11th Grade
10 questions
COMPUTER QUIZ 1

Quiz
•
11th Grade
10 questions
HTML Quiz

Quiz
•
12th Grade
8 questions
Code.org Unit 3 Review

Quiz
•
9th - 12th Grade
10 questions
AP CSP Big Idea 3 Practice

Quiz
•
9th - 12th Grade
13 questions
OCR J277 2.5.1 Languages

Quiz
•
9th - 10th Grade
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade
Discover more resources for Computers
50 questions
Trivia 7/25

Quiz
•
12th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade
6 questions
RL.10.1 Cite Evidence

Quiz
•
10th Grade
10 questions
Characteristics of Life

Quiz
•
9th - 10th Grade
14 questions
Algebra 1 SOL Review #1

Quiz
•
9th Grade