Big Idea 3 Questions Vs 01
Big Idea 3 Questions Vs 01
Practice Test
Question 1
Which of the following is NOT true about functions in programming?
A. Functions are reusable programming abstractions.
B. Functions help reduce the complexity of writing and maintaining programs.
C. Functions cannot make calls to other functions within the same program.
D. Once defined, a function can be called many times from different parts of a
program.
Question 2
Programming languages have some similarities and differences to the "natural"
language you use in everyday speech. Select the true statement about programming
languages:
A. Ambiguities in natural language necessitate the creation of programming
languages for controlling a computer.
B. There is only one possible way to interpret an instruction written in natural
language.
C. The number of defined words in a programming language is about the same
as the number of words in a natural language.
D. There are typically many possible ways to interpret an instruction written in a
programming language.
Question 3
What is one important naming convention of functions?
A. A function name should indicate how long the function takes to run.
B. Two functions with similar behavior should be given identical names to
indicate the relationship between them.
C. A function name should be as descriptive as possible to indicate what the
function does.
D. Function names should be organized alphabetically.
Question 4
Which one of the following statements about functions is TRUE?
A. A function can change names over the course of a program.
B. Code can be added or removed dynamically from a function while the
program is running.
C. Functions can be called using different names depending on where in the
program they are called.
D. Two functions in a single program can have different names but contain
identical code.
Question 5
A piece of code you can use over and over again
A. Function
B. Abstraction
C. Non-Function
D. Expression
Question 6
Pulling out specific differences to make one solution work for multiple problems
A. Top Down Design
B. Abstraction
C. Variable
D. None of the above
Question 7
Which of the following will call the function drawStar?
A. drawStar
B. drawStar();
C. function drawStar;
D. function drawStar();
Question 8
Why are parameters useful when programming?
A. Parameters allow for more flexible, generalized behaviors in functions.
B. Parameters determine the number of times the function will run.
C. Parameters are useful for teams of programmers because they help define
the boundaries of the problem they are trying to solve.
D. Parameters change the order of operations within a function.
Question 9
What is the most likely outcome of running the code shown at right?
Question 10
When programmers work together, what is an example of how abstraction in
programming can promote collaboration?
A. Team members can rely on one another to explain their code.
B. Programmers can write functions without needing to know what they do or
how they should work.
C. Programmers can use functions created by their partners, relying on the
functionality without needing to know the specific details of how the function is
implemented.
D. In order for programmers to work together, they must work in the same room.
Question 11
What is Abstraction?
A. The use of computers to solve problems.
B. Representing 'real world' problems in a computer using variables and symbols
and removing unnecessary elements from the problem.
C. Breaking down a large problem into smaller sub-problems.
D. Identifying the steps involved in solving a problem.
Question 12
How many times will this loop iterate?
A. 4
B. 5
C. 7
D. 6
Question 13
Why might this program produce an error in some programming languages?
Question 14
Which are true regarding high-level and low-level programming languages?
I. High-level can be more abstract
II. Low-level is harder to find errors
III. High-level is more easily understood by humans
A. I and II
B. I, II, and III
C. II and III
D. III only
Question 15
Which of the following images shows the path and ending location of the robot that
will result from executing the code below? The starting location of the robot is shown
as dotted triangle for cases where the robot does not start and end at the same
location.
A.
B.
C.
D.
Question 16
Knowing how to drive a car without knowing how the engine works is an example of
A. Abstraction
B. Function
C. Variable
D. Algorithm
Question 17
Any valid unit of code that resolves to a value
A. Expression
B. Equation
C. Program
D. Formula
Question 18
A placeholder for a piece of information that can change
A. Proxy
B. Element
C. Condition
D. Variable
Question 19
An expression that evaluates to true or false in programming is called _______.
A. Variable Expression
B. Algebraic Expression
C. Boolean Expression
D. Global Expression
Answer Key
1. C
2. A
3. C
4. D
5. A
6. B
7. B
8. A
9. D
10. C
11. B
12. D
13. A
14. B
15. B
16. A
17. A
18. D
19. C