exercise14 提示 传递
来源:互联网 发布:cacti后台sql注入漏洞 编辑:程序博客网 时间:2024/06/07 17:36
script, user_name = argv
prompt = '> ' #加一个提示
prompt = '> ' #加一个提示
print "Hi %s, I'm the %s script." % (user_name, script)
print "I'd like to ask you a few questions."
print "Do you like me %s?" % user_name
likes = raw_input(prompt)
print "I'd like to ask you a few questions."
print "Do you like me %s?" % user_name
likes = raw_input(prompt)
print "Where do you live %s?" % user_name
lives = raw_input(prompt)
lives = raw_input(prompt)
print "What kind of computer do you have?"
computer = raw_input(prompt)
computer = raw_input(prompt)
print """
Alright, so you said %r about liking me.
You live in %r. Not sure where that is.
And you have a %r computer. Nice.
""" % (likes, lives, computer)
Alright, so you said %r about liking me.
You live in %r. Not sure where that is.
And you have a %r computer. Nice.
""" % (likes, lives, computer)
$ python ex14.py zed
Hi zed, I'm the ex14.py script.
I'd like to ask you a few questions.
Do you like me zed?
> Yes
Where do you live zed?
> San Francisco
What kind of computer do you have?
> Tandy 1000
Alright, so you said 'Yes' about liking me.
You live in 'San Francisco'. Not sure where that is.
And you have a 'Tandy 1000' computer. Nice.
Hi zed, I'm the ex14.py script.
I'd like to ask you a few questions.
Do you like me zed?
> Yes
Where do you live zed?
> San Francisco
What kind of computer do you have?
> Tandy 1000
Alright, so you said 'Yes' about liking me.
You live in 'San Francisco'. Not sure where that is.
And you have a 'Tandy 1000' computer. Nice.
0 0
- exercise14 提示 传递
- linux exercise14
- linux exercise14
- 第五章 Neural Networks exercise14-25
- 练习14:提示和传递
- 习题14 提示和传递
- 习题14--提示和传递
- 笨办法14提示和传递
- Learn Python The Hard Way学习(14) - 提示和传递
- 学习随记-Toast提示,两个Activity之间传递数据
- 第14个python程序:提示和传递
- maven3.0.3编译报错,提示找不到传递依赖
- phpcms会员中心上传图片,传递参数有错误提示解决办法
- 笨方法学Python 习题 14: 提示和传递
- 【已解决】Django传递数据到js提示Unexpected token
- 笨方法学习Python-习题14: 提示和传递
- 笨办法学Python习题14 提示和传递
- 终于解决了--调用存储过程提示传递参数多的问题!
- oracle 如何查询当前连接的用户名
- Leetcode 415. Add Strings
- DSP 中的基础算法和模型的详细解析
- [14]CSS3 文本效果
- 如何降低App的待机内存
- exercise14 提示 传递
- 当你孤单你会想起谁
- 常用第三方开源代码库 (thirdparty/common)
- 6. 特定区域处理
- hsf dubbo学习八--延迟连接,粘滞连接,令牌验证,路由规则
- 2017年目标
- win7计算器功能详解
- SIOCADDRT: File exists
- Java读取Excel内容