Python Forum

Full Version: I do not understand why my python looks different from tutorials.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
For some reason mine looks like this:
https://imgur.com/a/4NLgRSP
But all the tutorials are like this:
https://imgur.com/a/5xtIS1r



Thanks in advamce!
"yours" is what we call python interactive mode. That is when on command line you type python (or python3) and hit Enter. You can see the interactive prompt >>>. Each line is executed when you hit Enter. This is for quick experiments, test ideas, etc. You want to write your code as scripts (in files) in order to be able to reuse them.
"tutorials" is some IDE (but could be just some text processing program like Notepad). In the IDE you write your script and save it as .py file and then on command line you eneter something like
C:\>python your_script.py (that on windows)

read this for different ways to execute python code

There are multiple threads that discuss different IDEs - you can search for them

Finally, in future don't post images, copy/paste code in python tags
Please, use proper tags when post code, traceback, output, etc.
See BBcode help for more info.
Is this what python shell is for?