SyntaxError: invalid syntax

23 views
Skip to first unread message

Ltc Hotspot

unread,
Oct 12, 2020, 10:45:01 AM10/12/20
to Project Jupyter

Hi Everyone

How do I remove the following message error, "SyntaxError: invalid syntax"?

See the attached file for details.

Thanks,

Hal
Screenshot 2020-10-10 165349.png
hello (1).py

Matthias Bussonnier

unread,
Oct 12, 2020, 12:29:57 PM10/12/20
to jup...@googlegroups.com
You are writing

print 'Hello', name

This is python 2 syntax, Python 2 has been end of life since Jan 2020,
when using Python 3 you want o use print with parenthesis.

print('Hello', name)

When looking on how to fix such error, you can look at any Python
resources, not Jupyter resources only.

Have fun starting programming in Python.
--
Matthias
> --
> You received this message because you are subscribed to the Google Groups "Project Jupyter" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to jupyter+u...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/jupyter/595b2bd3-e164-470e-a829-146708dc0fb6n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages