What can a function do?
Anything
Correctly increase a variable named i by 3
Does a string use double quotes or single quotes?
Both work
It is a keyword and cannot be a name.
What are the two main types of loops?
For and while
What keyword is used to end a function?
return
How can you print the statement:
Hello
World
In one line
Define an array with values of 1, 5, happy, no
arr = [1, 5, 'happy', 'no']
What version of python am I using?
Python 3.7.0
What comes after a while loop?
A conditional
What comes after the name of a function?
Parentheses
What can the name of a variable contain?
Letters and underscore
Get the subset of an array named arr starting from the 1st element and ending at the 5th element.
arr[0, 5]
Name 3 other programming languages other than Python?
Answers vary
How many times would "meow" print:
for i in range(2, 10, 2):
print("meow")
4
How does an array call a function?
[array name].[function name]
What is a conditional?
A true of false statement
How do you find the length of an array?
len(arr)
How many times will "meow" print out:
i = 3
while (i > 3):
print("meow")
i -= 1
What is it called when a function does not return any value?
Void
How does the computer know what code is inside of a function/loop and what is outside?
How do you remove and return the value at index 5?
arr.pop(5)
What are the two different ways to name a variable with multiple words?
camelCase and underscore
Using python and loops create a rectangle of stars with a width of 20 and a height of 100.