[PyCrumble No. 6] #Python __dunder__ special methods:
What is the difference between __repr__, __str__ and __format__? (4/4)
You can use __format__ also to create your own format specifications. Just be creative! 🤠
#teachingpython#pythonlearning
[PyCrumble No. 5] #Python __dunder__ special methods:
What is the difference between __repr__, __str__ and __format__? (3/4)
__format__ ensures that you can use Pythons format string mini-language with your objects. A basic usage could look like this beyond.
[PyCrumble No. 4] #Python __dunder__ methods: Difference between __repr__, __str__ and __format__ (2/4)
__repr__ is "what the developer wants to see", __str__ is "what the user wants to see". You want to implement __repr__ (especially for debugging) but __str__ not as necessary.
[PyCrumble No. 3] #Python __dunder__ special methods:
What is the difference between __repr__, __str__ and __format__?
__repr__ returns the canonical string representation, which can be evaluated and is also called by the standard str() function if __str__ is not implemented:
[PyCrumble No. 2] The minimum number of special- or "dunder"-methods to implement in your #python classes for your objects to behave like standard Python lists. In which other programing language can you do such cool things?
#pythonlearning#pythonistas#OOP
Classes in #python are definitely different from classes in more classical object-oriented programming languages like #java. They are more like namespaces or "object-protocols". What do you think? #teachpython#pythonlearning
Unsere Forschungsgruppe FALKO-PV der Universität Regensburg hat eine kostenlose Web-App zur anonymen Evaluation des Unterrichts durch Schüler:innen veröffentlicht.
➡️ mehr unter https://t.co/4ybOKPNSip
#twitterlehrerzimmer#lehrermangel#unterrichtsqualität#evaluation
@ProfAndyField So cool! I can see the cover for the 2nd Ed. of "Discovering statistics using R and RStudio"! But wheeeeen does it come out?!? 😩 It's 2023, and I'm so desperately waiting for it... fingers crossed. 🤞
@thephoeron That‘s why „Shin-Buddhism“ most famously through Shinran Shonin taught that u can‘t achieve and thrust all your hopes onto Amidha Buddha who accomplished for all to be born in his land of full bliss where achieving Buddhahood is much easier. 😉 Not kidding!
The 2022 state of #Haskell survey is now open! Please take a few minutes to fill it out. Thanks, and be sure to tell your friends! https://t.co/q5E6eZZDrl