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

Ok, I feel dumb but I'm hung up on ps0 - I can do the raw_input and get it to show Enter your last name: etc, but I'm missing how to get it to actually print just the name (unless all you do is type print Smith for example). I'm sorry, what am I missing???

OpenStudy (anonymous):

x=raw_input('something') print x This will print whatever you previously input. Get it?

OpenStudy (anonymous):

Ok, so you assign variables to various parts of the string and put the variables together? Sorry, I haven't written code since DOS...

OpenStudy (anonymous):

>>> x=raw_input('Enter your last name:') Enter your last name:Vander Ark >>> print x Vander Ark >>> y=raw_input('Enter your first name:') Enter your first name:Shanda >>> print y Shanda Like that?

OpenStudy (anonymous):

And chat is not letting me enter anything all of a sudden, geez, technology!

OpenStudy (anonymous):

Sure, but you might want to do something like this instead: x=raw_input('firstname') y=raw_input('lastname') print x,y

OpenStudy (anonymous):

Ok, now it makes sense, thank you! Sorry, it's been way too long! :) I was getting there at least!

OpenStudy (anonymous):

No problem. Don't forget to create a python file, instead of just writing code in the shell.

OpenStudy (anonymous):

Ok, so here goes, hoping it's not too far off...

OpenStudy (anonymous):

Ok, let's try this again, think this one is better...

OpenStudy (anonymous):

Alright, take three, not giving up til I get it right!

OpenStudy (anonymous):

It's fine

OpenStudy (anonymous):

Thank you so much! :)

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!