1. Command window into the Python installation directory
2.
>>> 100+200300
Quite simply, any valid mathematical calculation can be calculated.
If you want Python to print out the specified text, you can use a print statement, and then enclose the text you want to print in single or double quotes, but you can't mix single and double quotation marks:
Print ' Hello, World ' Hello, World
This text, enclosed in single or double quotation marks, is called a string in the program, and we will often encounter them in the future.
Finally, with the exit() exit Python, our first Python program is done! The only drawback is that it's not saved and you'll need to enter the code again the next time you run it.
Summary
Under the Python interactive command line, you can enter the code directly, then execute it, and get the results immediately.
Two, the first program of Python