Variables & Data Types
Functions & Pseudocode
Modules & Libraries
Conditional statements & Loops
Data Structures & Errors
100

What symbol assigns a value to a variable?

=

100

What keyword defines a function?

def

100

What keyword loads modules or libraries?

import

100

What keyword adds an alternative condition after if?

elif

100

What method adds an item to the end of a list?

.append()

200

What type is "1701"? 

String

200

What is pseudocode?

A roadmap/checklist for what to do in plain words

200

What keyword renames a module?

as (e.g. import pandas as pd)

200

What keyword stops a loop immediately?

break

200

What method removes the last key-value pair in a dictionary?

.popitem()
300

What type results from 1701 + 1.0?

Float

300

What keyword in a custom function makes the output reusable?

return

300

What does random.randint(1,10) do?

Generates a random integer between 1 and 10 (inclusive)

300

What keyword skips one iteration?

continue

300

How do you access the value for key "apples" in {"apples": 2}?

the_dict_name["apples"]

400

Which function checks a variable’s data type?

type()

400

What is the purpose of using parameters in a function?

Work as placeholders to pass data into a function

400

What’s the difference between a module and a library in Python?

A module is one python file with functions; a library is a collection of modules

400

What keyword means “run this code only if all prior conditions are false”?

else

400

What makes a tuple different from a list?

Tuples are immutable/unchangable

500

What error happens with 1701 + "1701"?

TypeError

500

What happens if you call a function before defining it?

Python throws a NameError

500

Why do we use modules/libraries?

To save time by using pre-written functions/tools

500

What is the main difference between for and while loops?

for runs fixed times; while runs until a condition is False

500

What’s the purpose of try/except?

Addressing an error without your program crashing/stopping

M
e
n
u