QUESTIONS AND CORRECT DETAILED ANSWERS WITH
RATIONALES
file = open(file_name) CORRECT ANSWER-open a file called 'file_name'
row = file.readline()
if row != ' ':
header = row.split()
else:
print('This file is empty.') CORRECT ANSWER-split up strings within text file by spaces
T CORRECT ANSWER-T/F:
A function may have multiple input parameters, which are separated by commas.
dictionary CORRECT ANSWER-
Fill in the blank: A namespace is actually just a normal Python whose keys are the names and
whose values are the objects.
age(19) CORRECT ANSWER-
Call a function named age, passing the value 19 as an argument. Do not include any unnecessary spaces
.
F CORRECT ANSWER-
T/F: A function with no return statement, or a return statement with no expression, like return, returns t
he value Zero.
yes CORRECT ANSWER-does this produce an error
def F():
a += 3