Earlier quoted context omitted.
Out of curiosity: why?
I can never remember the python 2 quirky, inconsistent syntax, I always have to look it up. PRINT TO A FILE, OR STDERR print >> sys.stderr, "blah" What are those '>' signs here? Why two? What happens if I use one only? Compare this to (py3k): print("blablah", file=sys.stderr) PRINT WITHOUT NEW LINE sys.stdout.write('blah') I can't use print to print? compare to: print("blah", end="") DISABLE FLIUSH In python 2 there…
You can. Compare the output from:
print "foo"
print "bar"
With that from: print "foo",
print "bar"