#/Convert numbers in range 1-10 to roman numerals Number = raw_input("Enter your number:\n") print if Number== "1": print "The Roman Numeral is I" print Number elif Number == "2": print "The Roman Numeral is II" print Number elif Number == "3": print "The Roman Numeral is III" print Number elif Number == "4": print "The Roman Numeral is IV" print Number elif Number == "5": print "The Roman Numeral is V" print Number elif Number == "6": print "The Roman Numeral is VI" print Number elif Number == "7": print "The Roman Numeral is VII" print Number elif Number == "8": print "The Roman Numeral is VIII" print Number elif Number == "9": print "The Roman Numeral is IX" print Number elif Number == "10": print "The Roman Numeral is X" print Number else:print("This is an error")
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