PRACTICE / UNDERSTAND / REPEAT

Python practice question

Practice equality & identity with self-contained questions. Check your answer, then use the explanation to understand the reasoning.

1 questionAnswers explainedFree · no login

Try this question

Equality & identity · MCQQuestion link ↗

Which operator checks whether two names refer to the same object?

Choose one answer
Answer & explanation

Answer: is

`is` tests object identity. `==` tests equality according to the objects’ equality behavior.