Glossary: Python Beyond the Basics
__repr__
Also written: repr, representation
A special method that returns the text Python shows when you print an object. Without it you see something like `<__main__.GiftCard object at 0x10a3f2b50>`.
Glossary: Python Beyond the Basics
Also written: repr, representation
A special method that returns the text Python shows when you print an object. Without it you see something like `<__main__.GiftCard object at 0x10a3f2b50>`.