Reputation: 31
It keep coming up with EOL while scanning string literal
but what does this mean?
This is the section it keeps calling an error:
if health2 <= 3:
print ("With all the strength you have left you attack one final time to deliver the
finishing blow. The zombie falls to the ground dead as you stand over it victorious. You can
now continue your quest to cross the country.")
Upvotes: 1
Views: 2019
Reputation:
It means that your string literal is malformed. You need to use triple quotes for a multi-line string:
if health2 <= 3:
print ("""With all the strength you have left you attack one final time to deliver
the finishing blow. The zombie falls to the ground dead as you stand over it victorious. You
can now continue your quest to cross the country.""")
String literals enclosed with just single quotes cannot span multiple lines.
Upvotes: 3