Basic Syntax with Python
An overview of basic syntax in Python.
StartKey Concepts
Review core concepts you need to learn to master this subject
Python main()
Function
Comments
print()
Function
Variables
Python type() function
Arithmetic Operations
Plus-Equals Operator +=
Modulo Operator %
Python main()
Function
Python main()
Function
def main():
print('Hello World!')
if __name__ == '__main__':
main()
The main()
function is used to define the starting point of our program. Including the main()
function allows us to import and run this program in another script.