MCQ Practice Single Best Answer Topic: Create Objects in Python

Q Which of the following execption occurs, when an undefined object is accessed?

Question ID
#20265
Subchapter
Create Objects in Python
Action
Choose one option below

Choose Your Answer

Click an option to check whether your answer is correct.

  • A UndefinedError
  • B VariableError
  • C NameError
  • D NonObjectError
Correct Answer: C

Explanation

The exception that occurs when an undefined object is accessed in Python is:


NameError

So, the correct answer is: NameError

Share This Question

Share this MCQ with your friends or study group.