Ask your own question, for FREE!
MIT 6.00 Intro Computer Science (OCW) 7 Online
OpenStudy (anonymous):

PS0 Final version. q1 = 'What is your given (first) name?' q2 = 'What is your family (last) name?' q3 = 'What is the relative computational speed of Unladen Swallow?' first = raw_input(q1) last = raw_input(q2) airspeed = raw_input(q3) print (first + ' ' + last + ', I think you need to watch some more Monty Python if you think it is ' + airspeed + '...') Spent a long time getting down the syntax. It really is like learning a whole new language. Any thoughts on my code?

OpenStudy (anonymous):

Does it run?

OpenStudy (anonymous):

Indeed. Test it out. It asks your name and then the other question. After you respond to the third prompt, it prints out your name using the "first" and "last" variables followed by the thread, then your value for the variable "airspeed" followed by a thread "..." I find that playing around with the overall pattern helps to drive home the syntax that you need to learn. For example, the bits in the parentheses for the raw_input() will be whatever it prompts you with to get data. By setting a variable to that value, you can essentially quote the user.

OpenStudy (anonymous):

That is great! I have to sprint to catch up because it runs so fast.

OpenStudy (anonymous):

do you get thrown off the bridge if you play the game? whats your favorite color?

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!