6. Expressions — Python 3 documentation#is
6.10.3. Identity comparisons
The operators
isandis nottest for an object’s identity:x is yis true if and only if x and y are the same object. An Object’s identity is determined using theid()function.x is not yyields the inverse truth value. [4]
Printed 2026-06-28.