__name__ Detailed

Insert picture description here
Insert picture description here
1. py is run as an entry
Insert picture description here
point. In summary, in a set of python programs,
there is always an entry module. The entry module prints the value of __name__, which is __main__, and prints the value of __name__ in other modules, which is the current module name.

Guess you like

Origin blog.csdn.net/weixin_43297727/article/details/115290194