Python Final Exam with answers |\ |\ |\ |\
Which is NOT a boolean expression - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\ |\
✔✔why
myList = |\ |\
['apples','oranges','grapes','pineapples','cherries','banana
s','blueberries','watermelon']
what is the value of myList[4] - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\ |\
✔✔cherries
Libraries are useless in python - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\
✔✔False
Which one is NOT a conditional statement - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔for |\
The way to save a file in this class is
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
FirstNameLastName.py - CORRECT ANSWERS ✔✔False |\ |\ |\ |\
Which one is NOT a valid variable? - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
✔✔num 1 |\
, my_word = "hello" |\ |\
what is the variable named in the line above? - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔my_word |\
The following code will store as a number NOT a string
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
cost1 = input('How much does it cost') - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔False |\
Which statements are NOT used for loops - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔loop i in len(myList): |\ |\ |\ |\
Local variables can be used anywhere in the program -
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
CORRECT ANSWERS ✔✔False |\ |\
Which print line is valid? - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\
✔✔print('This is my python code') |\ |\ |\ |\
What will this code generate when written on python?
|\ |\ |\ |\ |\ |\ |\ |\
ASSUMMING:
num1 = 6 |\ |\
num2 = 10 |\ |\
if num1<num2:
|\
print('number 1 is less than number 2') |\ |\ |\ |\ |\ |\
Which is NOT a boolean expression - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\ |\
✔✔why
myList = |\ |\
['apples','oranges','grapes','pineapples','cherries','banana
s','blueberries','watermelon']
what is the value of myList[4] - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\ |\
✔✔cherries
Libraries are useless in python - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\
✔✔False
Which one is NOT a conditional statement - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔for |\
The way to save a file in this class is
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
FirstNameLastName.py - CORRECT ANSWERS ✔✔False |\ |\ |\ |\
Which one is NOT a valid variable? - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
✔✔num 1 |\
, my_word = "hello" |\ |\
what is the variable named in the line above? - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔my_word |\
The following code will store as a number NOT a string
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
cost1 = input('How much does it cost') - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔False |\
Which statements are NOT used for loops - CORRECT
|\ |\ |\ |\ |\ |\ |\ |\ |\
ANSWERS ✔✔loop i in len(myList): |\ |\ |\ |\
Local variables can be used anywhere in the program -
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\
CORRECT ANSWERS ✔✔False |\ |\
Which print line is valid? - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\
✔✔print('This is my python code') |\ |\ |\ |\
What will this code generate when written on python?
|\ |\ |\ |\ |\ |\ |\ |\
ASSUMMING:
num1 = 6 |\ |\
num2 = 10 |\ |\
if num1<num2:
|\
print('number 1 is less than number 2') |\ |\ |\ |\ |\ |\