CMU Unit 2.2.4 and 7.2 Variables

Flashcard
•
Computers
•
9th Grade
•
Hard
Wayground Content
FREE Resource
Student preview

14 questions
Show all answers
1.
FLASHCARD QUESTION
Front
A variable declared within a subroutine or function
Back
Local
2.
FLASHCARD QUESTION
Front
A variable declared in the main program
Back
Global
3.
FLASHCARD QUESTION
Front
The correct way to write a variable in Python? Options: myVariable = 10, my Variable = 10, myVariable is 10, myVariable: 10
Back
myVariable = 10
4.
FLASHCARD QUESTION
Front
Which of the following is an advantage of using local variables? They allow the variable to be used throughout the whole program, They allow variable identifiers to be reused each time, They are easier to program than global variables, A wider range of data types can be used
Back
They allow variable identifiers to be reused each time
5.
FLASHCARD QUESTION
Front
What term is used to describe data passed into/out of a program?
Back
Parameter
6.
FLASHCARD QUESTION
Front
Leo wants to create a subroutine / function that will roll a dice. Which syntax is correct? Options: def dice roll ():, def diceroll (), def diceroll ():, def diceroll []:
Back
def diceroll ():
7.
FLASHCARD QUESTION
Front
Which of the following is an advantage of using global variables? They allow the variable to be used throughout the whole program, They allow variable identifiers to be reused each time, They are easier to program than global variables, A wider range of data types can be used
Back
They allow the variable to be used throughout the whole program
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Math 2 wk 3

Flashcard
•
9th Grade
15 questions
Two-Step Inequalities

Flashcard
•
9th Grade
15 questions
Algebra Final Test - REVIEW

Flashcard
•
9th Grade
15 questions
1-4 Literal Equations and Formulas

Flashcard
•
9th Grade
15 questions
One and Two Step Inequalities

Flashcard
•
9th Grade
15 questions
Single Variable Inequality Flashcard

Flashcard
•
9th Grade
15 questions
Crunch Time Week 1 Flashcard

Flashcard
•
9th Grade
15 questions
Equations of Circles

Flashcard
•
9th 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
Appointment Passes Review

Quiz
•
6th - 8th 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
20 questions
Grammar Review

Quiz
•
6th - 9th Grade