Just today I installed Python and started studying. Wrote in IDLE:
& gt; & gt; & gt; print ("hello world")
IDLE returned, everything is super. Saved in hw.py, the interpreter does not run the file and swears like this
“SyntaxError: unexpected character after line continuation character”
What does he want from me?
Answer 1, authority 100%
In your hw.py
file, somewhere in the line you have a \
symbol and something else behind it – you don’t see it, because it is somewhere behind the right edge of the window.
Go through each line and on each of it press the End key on your keyboard.
Then delete unnecessary characters, save the file and write again
python hw.py
Answer 2
The encoding is worth checking, it should be utf-8, I had this if the file is saved in cp1251