What is print, and why is it in white text?

Question

What is print, and why is it in white text?

Answer

Print is what we use to display text to the screen. The word itself is white because of how the Codecademy editor colors that Python keyword - a word reserved by the language.
Pro tip! As you code more, you’ll get used to how your editor (Codecademy, in this case) highlights certain words and variables, and it’ll help you notice when something’s off.

5 Likes

As we transition from Python 2 to Python 3, some slight change in syntax needs to be learned. We can use Python 3 syntax on our print statements in Python 2 with no effect, and get in the habit of using parentheses on print statements.

print ("Python 3 requires parens because `print()` is a function.")
16 Likes

8 posts were merged into an existing topic: Learn Python 2 How do i create a variable call Ceaser? Let me know soon