Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
The print function
6. Printing strings and numbers together
Variables
Math in Python
The input function
Summary

Instruction

Great! You can also use print() to show strings and numbers together:

print('Current year is:', 2018)

The result will be:

Current year is: 2018

Inside print(), we used a comma to separate a string from a number. Python will automatically add a space between these two arguments.

Exercise

Print the following sentence: Python first appeared in 1990.

Stuck? Here's a hint!

Inside the parentheses of print(), use:

'Python first appeared in', 1990