I've been getting a runtime error with the raw_input exercise. I've been racking my brain with these two sources of documentation. http://wiki.python.org/moin/SimplePrograms http://en.wikibooks.org/wiki/Python_Programming/Input_and_output Can someone be kind enough to give me a little insight as to what I'm doing wrong?
What's your code look like?
What version of Python?
x = input('What is your name?\nPlease type your name here:') print 'Hello %s' % x
Currently running Python 2.6.7
You try putting parenthesis around your print statement? x = input('What is your name?\nPlease type your name here:') print ('Hello %s'% x)
The code still doesn't work :-(
x = raw_input('What is your name?\nPlease type your name here:') print 'Hello %s' % x What is your name? Please type your name here:slick Hello slick >>>
Works in 2.7. It could be why they suggest that you use 2.7.5 in the exercises.
Perfect! No more runtime :) Thank you very much eSpeX!
You're welcome.
Join our real-time social learning platform and learn together with your friends!