Logo
Python Snacks
Logo
Articles
Advertise
Contact
Books
Sign Up

metaprogramming

getattr, setattr, __new__, dynamic classes.


4 types of Python dunder (magic) methods you should know

4 types of Python dunder (magic) methods you should know

Dunder methods can change your python game significantly if you know how to leverage them correctly.

Nov 27, 2024

•

6 min read

The difference between __repr__ and __str__

The difference between __repr__ and __str__

Understanding Python’s String Representations for Developers and Users

Nov 20, 2024

•

4 min read

What is __name__ == "__main__"?

What is __name__ == "__main__"?

See how this can affect your Python code during run time.

May 22, 2024

•

5 min read

Demystifying the init python file

Demystifying the init python file

What does the __init__ file do, and why do I need it?

Apr 10, 2024

•

4 min read

background

Become a better software engineer today.

Newsletter

Login

Upgrade to Pro

Sample Issue

Advertise

Tools

Tutorials

Templates

Resources

Newsletter

Blog

Latest Posts

Experts

Creators

Most Popular

Resources

Support

Recommendations

Software Engineering Books

© 2025 Python Snacks.

Privacy policy

Terms of use

Powered by beehiiv