Created
February 16, 2013 19:30
-
-
Save Kwpolska/4968352 to your computer and use it in GitHub Desktop.
Python print() — 2.7 vs 3.3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ python2 -c 'print("python", "2")'; python3 -c 'print("python", "3")' | |
('python', '2') | |
python 3 | |
$ python2 -c 'from __future__ import print_function; print("python", "2")' | |
python 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment