Alternate assignment: Unit 7 test

Quiz
•
Computers
•
8th Grade
•
Medium
CRYSTAL DEMOURA
Used 2+ times
FREE Resource
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Which of the following is NOT a reason we use subprograms (functions)?
For code that will be reused
To test for true and false relationships
To simplify code
To help us organize longer programs
2.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Which of the following parameters is optional?
sample (a, b, c, d = 121)
a
d
c
b
3.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Consider the following subprogram: def mult(a, b = 1, c = 1): print(a * b * c) What is output by: print(mult(3, -10))
0
31
-30
30
4.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
We call the central part of the program the __________ program.
main
def
sub
return
5.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Which of the following is NOT a subprogram?
random
input
randint
6.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Consider the following code:
def tryIt (an):
val = an * 2
c = 0
if (val < 0):
c = 1
return c
Which variable is the parameter?
val
c
an
0
Answer explanation
an - The parameter is the variable passed into the function in the parentheses when it is originally defined.
7.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Subprograms go __________ the main program.
outside
after
inside
above
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Robotics Intro

Quiz
•
8th Grade
15 questions
Python Objective 2

Quiz
•
8th Grade
15 questions
PyGame Zero - 3

Quiz
•
7th - 8th Grade
15 questions
Coding Quiz

Quiz
•
6th - 10th Grade
19 questions
Grade 8

Quiz
•
8th Grade
16 questions
Exploring String Slicing in Python

Quiz
•
8th Grade
15 questions
Lập trình hướng đối tượng

Quiz
•
1st - 12th Grade
20 questions
Y8 Edu:bit Assessment

Quiz
•
8th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

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

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
18 questions
Company Logos

Quiz
•
6th - 8th Grade
10 questions
Exploring Cybersecurity Techniques and Threats

Interactive video
•
6th - 10th Grade
10 questions
Understanding the Internet and Data Transmission

Interactive video
•
7th - 12th Grade
25 questions
How to Email a Teacher- https://youtu.be/NioeNhfpVfI

Quiz
•
6th - 8th Grade
20 questions
Computer Hardware

Quiz
•
6th - 8th Grade
21 questions
Gear Ratio Practice

Quiz
•
6th - 8th Grade