Under and Dunder - Python secret functions
You may know dunder init (
__init__), but how well do you know about other Python “magic” functions? Why are dunder functions not accessible? in this talk, I am going to show you the secrets of the Dunder functions and what purposes they have. Once the mystery is solved, we will see the beauty of those functions.
At the start, we will be using
dir to look into the secret functions Python objects have. Eg:
__next__ Then, we will investigate where is the dunder function goes? Why is it not accessible. And at the end, we will see how dunder functions can change the identity of the Python objects.
This talk is for attendees who have just begin their Python journey. By explaining the dunder functions and the nature of Python objects, attendees will have a better understanding of why Python is fundamentally different from other programming languages. Hopefully, this knowledge will help them out when they continue their Python journeys.
After having a career in data science, Cheuk now brings her knowledge in data and passion for the tech community into TerminusDB as the developer relations lead. Cheuk constantly contributes to the open-source community by giving free tutorials on Twitch and organize sprints to encourage diversity contributions.