my_name = 'Thomas Marshall' my_age = 35 my_height = 74 my_weight = 180 my_eyes = 'brown' my_teeth = 'white' my_hair = 'black' print "Let's talk about %s." % my_name print "He's %d inches tall" % my_height print "He's %d pounds heavy." % my_weight print "Actually that's not too heavy" print "He's got %s eyes and %s hair." % (my_eyes, my_hair) print "His teeth are usually %s depending on coffee." % my_teeth # this line is tricky, try to get it exactly right print "If I add %d, %d, and %d I get %d." % (my_age, my_height, my_weight, my_age + my_height + my_weight)
Run
Reset
Share
Import
Link
Embed
Language▼
English
中文
Python Fiddle
Python Cloud IDE
Follow @python_fiddle
Browser Version Not Supported
Due to Python Fiddle's reliance on advanced JavaScript techniques, older browsers might have problems running it correctly. Please download the latest version of your favourite browser.
Chrome 10+
Firefox 4+
Safari 5+
IE 10+
Let me try anyway!
url:
Go
Python Snippet
Stackoverflow Question