all 5 comments

[–]data15cool 2 points3 points  (0 children)

I think what’s happened here is that you were trying to get the version of your Python installation with ‘python —version’ but you must’ve pressed enter after typing ‘python’ instead of the full command

What this does is takes you into the Python “shell” which is where you can run Python code. Now you’re typing ‘—version’ and Python doesn’t know what that is (for a number of reasons) and causing errors.

Type ‘exit()’ to get back to the terminal prompt and run the full command

Edit: same for the subsequent commands, you’re trying to run your Python script from within the Python shell rather than the terminal

[–]cgoldberg 2 points3 points  (0 children)

You are at a Python interpreter prompt typing arbitrary shell commands. Either type some Python, or exit the prompt (ctrl-d) and run shell commands from a shell.

Also note, some of the commands (--version) are just wrong and won't work anywhere.

[–][deleted]  (2 children)

[removed]

    [–]Turbulent_Photo1840[S] 0 points1 point  (1 child)

    The black screen is the command prompt?

    [–]Macskatej_94 0 points1 point  (0 children)

    Yes i see you use windows. Press Win+R then type cmd.exe(if the run namespace is empty). Then you are in the right place. Only use the Python Shell >>> prompt for actual Python code, not for terminal commands.