Command for creating a new folder
What is mkdir?
The four data types we know so far:
What are:
Strings
Integers
Floats
Lists ?
Another name for an if/else statement.
What is a conditional?
Name of the loop that goes through each item in a data type
What is a for loop?
The name of the coding environment we use for Python
What is Jupyter Notebook?
What pwd stands for
What is Print Working Directory?
What would this look like exactly in the terminal?
print("Fish" + '7')
What is Fish7 ?
The three key words for a conditional statement
What are if, elif, and else?
What is the output of this program?
for x in range(0, 56):
print (x)
What is
0
1
2
...
55 ?
GitHub uses these two types of folders/repositories:
What are:
Local Repository
Remote Repository ?
I want to make a folder called Cats and make a txt file called MaineCoones inside of it. What do I write in the terminal?
mkdir Cats
cd Cats
touch MaineCoones.txt
What would this program output?
x = 7.5
y = int(7.5**2) + 56
print (y)
What is 112?
What would this program output?
fruits = ["apples", "pears," "oranges", "tomatoes", "berries"]
random = ["grapes", "pears", "grapefruits", "pomegranates", "apples"]
for x in random:
if x not in fruits:
fruits.append(x)
else:
random.remove(x)
print (fruits)
print(random)
["apples", "pears," "oranges", "tomatoes", "berries", "grapes", "grapefruits", "pomegranates"]
["grapes", "grapefruits", "pomegranates"]
What is the output of this program if the user inputs 'Mary Sue'.
name = input("What is your name?")
for x in name:
print name[x+1]
What is :
A
R
Y
S
U
ERROR ?
The reason Python is called Python
What is Monty Python?
I want to see everything inside of a folder called Pringles on my Desktop and move some files into a different folder called Lays. How?
cd Pringles
ls
mv file1.txt Lays
What would this program output?
name = Ivy
print (name + "is awesome.")
ERROR
Do if/else statements require an "else"?
No
Describe what this does (in words).
coolestPpl = ['Ivy', 'Mary Sue', 'Mr. Paranya', 'Debby']
for person in coolestPpl:
a = coolestPpl.index(person)
b = a + 1
coolestPpl[b] = coolestPpl[a]
coolestPpl[a] = coolestPpl[b]
Swaps the names in the list.
The name for the act of using a function you've defined. + BONUS How do you do it?
What is calling a function?
BONUS: functionName(parameter)
The FULL directory path to a folder named Cats located in your Desktop.
What is /Users/MyLaptopName/Desktop/Cats ?
Name another data type that is not one of the four we already discussed.
What is
Boolean (True/False)
Dictionaries
Sets
Tuples ?
What would this program output?
cool = "Debjani"
if 'Debjani' == cool:
print (":)")
cool = 'Ivy'
elif 'Ivy' == cool:
print (":(")
What is :) ?
What is an ordered version of a list that contains no duplicates?
What is a set?
What does this program output?
list = [4, 5, 6, 7, 8]
def ConvertNum():
for num in list:
num = num **3
return num
ConvertNum()
What is 64?