1, the program entrance, let main show out:
Print (__name__) #__name___是模块中的隐藏字段, function name of the current module run
if __name__ = = __main__
__MAIN__ ()
#定义程序入口: In Python, the main function is hidden by default, and the main function, under the currently running module, defines the program entry to make the main function explicit #现出来
Def __main__ ():
。。。。。。。
2. Object-oriented and process-oriented:
Object-oriented: Use objects to accomplish tasks, do not need to care about the process;
3. What is a class: A type that defines class to represent a type of information, such as int, function is a class, and we can define our own classes as needed,
Class Alei ():
A = 1;
b = 3;
DEF ABC ():
....
This allows us to generate a alei that can be viewed with type ()
Object oriented and process oriented, the entry--main method of the program in the class Class,python in Python,