#!/bin/python
#coding=gbk
#python猜数游戏
#
import random
i = 0
while True:
answer = random.randrange(0,100)
enter_num = int(raw_input('请输入猜的数字(0-100): '))
if enter_num <= 100 and enter_num >=0:
if enter_num == answer:
print '恭喜您,猜中了...!请继续!n'
continue
else:
i += 1
print '您猜错了,您还有 %d 次机会n ' % (6-i)
if i > 5:
print '您已经失去五次机会。。。。!!n'
break
else:
print '请输入一个规定的数值!!n'