Why You Should Use Python if __name__ == “__main__”?

Have you ever wondered that Python doesn’t have a main function but people are using if __name__ == __main__: in their code?
Checkout my latest Youtube video and this blog article to find it out why:
https://k0nze.dev/posts/python-name-main/

原文链接:Why You Should Use Python if __name__ == “__main__”?

© 版权声明
THE END
喜欢就支持一下吧
点赞6 分享
评论 抢沙发

请登录后发表评论

    暂无评论内容