李金龙
李金龙
李金龙
厉害了
这个是什么 要写程序的么,怎么都在李金龙
{:10_249:}
派送菜鸟 发表于 2017-7-10 10:25
这个是什么 要写程序的么,怎么都在李金龙
别理他们,写程序
c = ['Alan','Bob','Clara']
name = input("Please enter a name:\n")
#count = 0
while True:
if name in c:
print("Congratulations! You are right!")
break
else:
print("Sorry, please try again!")
name = input()
题目
分享
???
#coding=gbk
print('欢迎来到猜名字游戏!')
name=['大熊猫','狮子','老虎']
while True:
shuru=input('请输入动物的名字:')
if shuru in name:
print('恭喜你!猜对了!')
else:
print('再试一次!')
import random
secret = random.randint(1,10)
temp = input("在1-10中猜一下我心里想的是哪个整数:")
guess = int(temp)
i = 3
while guess != secret and i>=2:
i=i-1
if guess > secret:
print("大了,猜的数大了")
temp =input("请再猜一次吧:")
guess = int(temp)
else:
print("小了,猜的数小了")
temp = input("请重新输入吧:")
guess = int(temp)
if guess == secret:
print("厉害了,竟然猜中了")
else:
print("猜3次都没有对,没有机会了")
print("游戏结束了")
import random
a=random.randint(0,3)
names=['小鱼儿','花无缺','wzxjzrz','韩66']
answer=names
print('今天我们玩一个猜名字的游戏,现在有这些名字:',names)
times=0
while len(names)>0 and times<10:
guess=input('选一个吧:')
if guess not in names:
print('错了,不要随便乱敲')
print('你敲的是',guess,'不在范围内')
times+=1
if times==9:
print('只有最后一次机会了啊!')
continue
if guess==answer:
print('不是吧,这么快就才对了,没意思,不玩了!')
break
else:
print('不是这个啦,重来!')
names.remove(guess)
times+=1
if times==9:
print('只有最后一次机会了啊!')
print('游戏结束!')
哈哈
I Love FishC
李金龙
小甲鱼
李金龙
李金龙