TheLearningDev's Blog

TheLearningDev's Blog

Subscribe to our newsletter and never miss any upcoming articles

What is __name__ == "__main__" in Python?

Bhavani RaviBhavani Ravi
Nov 22, 20221 min read

Python snippets use name == "main" checks to ensure that the module-specific code is run only when they are run directly via Python. If you are a...

What is __name__ == "__main__" in Python?
When to use List vs Dict in Python?
First OpenSource Contribution? Don't Start at Good First Issue
Python: Iterables and Iterators
"yield" keyword in Python
7 Programming Anti-Patterns