
Python- Variables

Quiz
•
Computers
•
3rd Grade
•
Hard
Aram M
Used 1+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is a variable in Python?
A type of function in Python
A special character used in Python coding
A type of snake in the Amazon rainforest
A reserved memory location to store values
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How do you declare a variable in Python?
variable = value_name
value = variable_name
variable_name = value
name = variable_value
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What are the rules for naming a variable in Python?
Variables cannot contain numbers
Variables can start with any special character
Variables must start with a letter or underscore, followed by letters, digits, or underscores. They are case-sensitive and cannot be a keyword.
Variables are not case-sensitive
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the difference between local and global variables in Python?
Local variables are defined within a function and can only be accessed within that function, while global variables are defined outside of any function and can be accessed throughout the entire program.
Local variables are defined within a function and can be accessed throughout the entire program, while global variables are defined within a function and can only be accessed within that function
Local variables can be accessed throughout the entire program, while global variables are defined within a function
Local variables are defined outside of any function and can be accessed throughout the entire program, while global variables are defined within a function
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Give an example of a variable assignment in Python.
x = 5
z = True
y = 3.14
x = 'hello'
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What are the different data types in Python?
red, blue, green, yellow, purple
integer, float, string, list, tuple, dictionary, boolean
apple, banana, orange, grape, watermelon
dog, cat, bird, fish, rabbit
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the difference between int and float data types in Python?
int represents letters and float represents special characters
int represents even numbers and float represents odd numbers
int represents whole numbers and float represents numbers with decimal points
int represents negative numbers and float represents positive numbers
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Coding Challenge for Grade 3

Quiz
•
3rd Grade
10 questions
Bài 1. Làm quen với Python

Quiz
•
1st - 5th Grade
15 questions
Python Basics

Quiz
•
KG - University
15 questions
Scope of Variables in Python

Quiz
•
1st Grade - Professio...
10 questions
Quiz1_HPB2021_2010t1

Quiz
•
1st - 12th Grade
10 questions
Prueba Diagnóstica de ED. a través de tecnologías digitales

Quiz
•
1st Grade - University
10 questions
CodeTigers Python 101

Quiz
•
KG - Professional Dev...
14 questions
Python- wprowadzenie

Quiz
•
1st - 6th 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
20 questions
Run-On Sentences and Sentence Fragments

Quiz
•
3rd - 6th Grade
20 questions
4 Types of Sentences

Quiz
•
3rd - 5th Grade
10 questions
Place Value

Quiz
•
3rd Grade
17 questions
Multiplication facts

Quiz
•
3rd Grade
12 questions
Damon and Pythias

Quiz
•
3rd Grade
20 questions
Subject and Predicate Review

Quiz
•
3rd Grade
20 questions
Division Facts

Quiz
•
3rd Grade
18 questions
Hispanic Heritage Month

Quiz
•
KG - 12th Grade