Hello all,
I am newcomer having hard time with these codes. I got an error message when I try to run the code. The error message states that ‘Syntax error EOL wile scanning single-quoted string’. I have the error image for more information. Please explain me in detail to fix the error. Your help is great. Thanks a lot.
Syntax Error
EOL while scanning single—quoted string
File: “Untitled Script 2”, line 2
print “Here are the ten numbers from 0 to 9
Cancel Edit
Syntax error EOL while scanning single-quoted string’
The Error stated, the EOL or End of Line, is triggered by undetermined ending tag. For example, a “(” ends with an “)”, and also for strings the whole sentence should be in between two quotation marks ( ” or ‘ ) at the beginning and end.
The wrong part is only a simple end quotation for your print function. Here:
Rather than:
print “Here are the ten numbers from 0 to 9
It should be:
print “Here are the ten numbers from 0 to 9”
There you go! A simple semantic error causing great problems(?).
Check the other parts of your code for similar errors.