Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #http://learnpythonthehardway.org/book/ex14.html
- # run this script passing 1 argument
- #eg
- #C:\Python33>python PTHW14.py NAME
- from sys import argv
- script, user_name= argv
- prompt = '>'
- print ("Hi {}, I'm the {} script".format(user_name, script))
- print ("I'd like to ask you a few questions.")
- like = (input("Do you like me {}?".format(user_name)))
- lives = (input("Where do you live {}?".format(user_name)))
- computer = (input("What kind of computer do you have {}?".format(user_name)))
- print ("""
- Alright, so you said {} about liking me.
- You live in {}. I'm not sure where that is.
- And you have a {} computer. Cool
- """.format(like,lives,computer))
Add Comment
Please, Sign In to add comment