ENGINEERING 102 TAMU FINAL EXAM QUESTIONS
WITH CORRECT ANSWERS
In a Python dictionary, for a given key, there is a single ___________. - CORRECT ANSWER-value
What is the output for the following code?
drinks = ['soda','water','lemonade','orange juice']
favorite_drink = drinks[0:2]
print(favorite_drink) - CORRECT ANSWER-['soda', 'water']
What is the output in the console for the following Python program?
candy = [15, 12, 50, 18]
candy[2] = 11
print(candy) - CORRECT ANSWER-[15, 12, 11, 18]
What is the output for the following Python program?
candy = [15, 12, 50, 18]
candy[2] = 11
print(candy[1:3]) - CORRECT ANSWER-[12, 11]
What is the output for the following Python program?
candy = [15, 12, 50, 18]
candy[2] = 11
Engineering 102 TAMU Final exam questions with correct answers
WITH CORRECT ANSWERS
In a Python dictionary, for a given key, there is a single ___________. - CORRECT ANSWER-value
What is the output for the following code?
drinks = ['soda','water','lemonade','orange juice']
favorite_drink = drinks[0:2]
print(favorite_drink) - CORRECT ANSWER-['soda', 'water']
What is the output in the console for the following Python program?
candy = [15, 12, 50, 18]
candy[2] = 11
print(candy) - CORRECT ANSWER-[15, 12, 11, 18]
What is the output for the following Python program?
candy = [15, 12, 50, 18]
candy[2] = 11
print(candy[1:3]) - CORRECT ANSWER-[12, 11]
What is the output for the following Python program?
candy = [15, 12, 50, 18]
candy[2] = 11
Engineering 102 TAMU Final exam questions with correct answers