Skip to content

Instantly share code, notes, and snippets.

@Kwpolska
Created February 16, 2013 19:30
Show Gist options
  • Save Kwpolska/4968352 to your computer and use it in GitHub Desktop.
Save Kwpolska/4968352 to your computer and use it in GitHub Desktop.
Python print() — 2.7 vs 3.3
$ 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