unit 5
Operators & Conditionals
Loops
String Indexing
Misc.
100

Every files in the file system can be identified using a unique (BLANK)

absolute path 

100

The 2 Boolean values 

What are True and False? 

(follow-up question: What are the naming conventions of True and False? Do they need to be capitalized? )

100

The word used to refer to each time the loop executes the block of statements in its body

What is an iteration ?

100
Characters enclosed in quotes

What is a String? 


Follow-up: double or single quotes? 

100

When the debugger encounters this the execution will stop and the debugger controls open

what is a breakpoint? 

200

this function will open and return the file at the specified path 

What is an open(path)?

200

The 2 Types of operators that python supports 

What are Relational and Logical


(follow-up question: Tell me some relational and logical operators ) 

200

2 Control statements you learned in class 

What are break and continue? 

follow-up: can someone tell me what break does, someone else what continue does? 

200

The type of sequence that begins with a backslash ('\')

what is an escape sequence ?

follow-up: Can you name any escape sequences?

200

the command that puts the remote repo on your local machine

what is git clone

300

This function returns a copy of the string with any leading and trailing whitespace removed

what is strip()

300

Fill in the Blank: Conditional Statments that are chained together are {Blank} 


Hint: 2 words 

what is mutually exclusive? 


(follow-up: can someone explain what this means?)

300

What is the output of this code? 

count = 0 

 while count < 5:   

 print("Count is ", count ,"\n")    

count += 1  

print("Loop finished")

Count is 0
Count is 1
Count is 2
Count is 3
Count is 4
Loop Finished

300

Function that gets the length of a string 

what is len()?
300

The function that tokenizes string 

What is split? 

follow-up: what does tokenize mean? and how does split decide how to split up strings?

400

calling this functions makes files avaible for use by other programs ?

What is close()?

400
The keyword used to denote what you should do instead if your conditional is false.
What is Else? Elif?
400

the type of loop in python that works with ranges

what is a for_loop?

400

The output of the following "code": 

first= Keanu 

last= Reeves 

print( first + name ) 

What is John Wick? i mean Keanu Reeves.


follow-up: what is this operation called?

400

The scope of a variable initialized outside of any function? 

what is global? 

follow-up: what is scope?

500

What does CSV stand for ?

Comma seperated Values


500

On the board write a conditional that does the following: 

 I have 2 points A and B and I want to add them together if A is even and B is less than 10, otherwise subtract them.

if A % 2 == 0 and B < 10 : 

return A+B 

else: 

return A-B

500

Range() can take up to3 parameters ? What are they 

Start, stop, k 

follow-up: what do these represent?

500
How would i print the letter 'W' from the word "John Wick"


word= "John Wick"

print( word[5])


follow-up: Do string indexes start at 1 or 0 ?

500

What is the name of professor Bobby's dog?

who is hermione?