0
I’m starting to study programming. I downloaded version 3.8.3 of Python and to write the programs I downloaded the Sublime text that allows running the programs on the platform itself.
When I started working normally, I was able to run the programs in both Sublime text and Windows prompt (I have Windows 10), but I did not study for a while and when I went back now the print function does not work through the prompt, only through Sublime text. When I try to run through the prompt the window opens and closes very quickly, which didn’t happen before.
The strange thing is that my girlfriend sent me a program by email and the program she made runs smoothly by Windows prompt, but the ones I do on my computer do not.
I tried to see if it was a typo, so I wrote a very simple program:
print ("Hello World")
And yet it didn’t work.
I already uninstalled and installed Python and nothing. I tried writing the program using another text tool and it didn’t work either. I saw that I could look at Python’s help() to see if everything was right and it is.
Is it some problem with Windows?
During the installation of the
Python
(official website) the installer asks if you wantcriar
the Python environment variable. If you are disabling this option during installation, Python will not bereconhecido
in theprompt de comandos
. I suggest reinstalling Pythonhabilitando
the definition ofvariável de ambiente
.– Solkarped
Another thing, it’s good to know that
atualmente
exists in operation two versions of Python incompatible with each other. The version2
and the version3
. This means that, programs created inPython 3
will not be executed by version interpreters2
or vise-versa.– Solkarped