Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Heres a python 2 version:
- print "%s%d" % ('2+3=',5)
- # or a stranger variation
- print "{}{}".format("2+3=",5)
- # On this one you need as many {} as variables, and the separator you put
- # between the {} and the next {} is the separator between your output variables.
- # This little python 3 to 2 trick also works:
- from future import print_function
- print ("this", 5, sep='')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement