55264-A: Introduction to Programming Using Python Quiz Questions and Answers

Which of the following is an invalid statement?

Answer :
  • x y z = 1 2 3

Which of the following is not a keyword?

Answer :
  • Open

What is the maximum possible length of an identifier?

Answer :
  • 79 characters

Suppose t = (1, 2, 4, 3), which of the following is incorrect?

Answer :
  • t[3] = 45

Which of the following is a Python tuple?

Answer :
  • (1, 2, 3)

Which of the following option is not a core data type in the python language?

Answer :
  • Class

Which of the following data types is shown below? L = [2, 54, 'hello', 5] What will be the output of this statement?

Answer :
  • List

What happens when '2' == 2 is executed?

Answer :
  • False

What does 3 ^ 4 evaluate to?

Answer :
  • 7

What will be the output of the following Python code? t=(1,2,4,3) t[1:-1]

Answer :
  • (2, 4)