PYTHON SYNTAX _2/14

Print Statements

There are two different Python versions. Both Python 2 and Python 3 are used throughout the globe. The most significant difference between the two is how you write a print statement. In Python 3, print has parentheses.
print("Hello World!") print("Deep into distant woodlands winds a mazy way, reaching to overlapping spurs of mountains bathed in their hill-side blue.")

In this course, we will be using Python 2. If you go on to write Python 3 it will be useful to note this key difference.

Exercise
  1. Print something using Python 3's syntax.

1 comment:

Powered by Blogger.