# coding:utf-8
from random import randint
num=randint(1,100)
print "guess the right number ,so please input a number:"
a=1
while a==1:
answer=input() ##把输入赋值给answer以便条件中用到比较大小
if answer<num :
print "it‘s too small"
if answer>num :
print "it‘s too big"
if answer==num :
print "right"
本文出自 “飞舞的青春” 博客,转载请与作者联系!
原文地址:http://2632788.blog.51cto.com/2622788/1608073