#!/usr/bin/env python
# coding=utf-8
# Created Time: 2017-08-07 12:39:38
# Modified Time: 2017-08-08 13:10:17
number = 23
running = True
while running:
guess = int(raw_input('Enter an integer : '))
if guess == number:
print 'Congratulations,you guessed it.'
running = True # this causes the while loop to stop
elif guess < number:
print 'No,it is a little higher than that'
running = True
else:
print 'No,it is a little lower than that'
running = False
else:
print 'The while loop is over.'
# Do anything else you want to do here
print 'Done'
# coding=utf-8
# Created Time: 2017-08-07 12:39:38
# Modified Time: 2017-08-08 13:10:17
number = 23
running = True
while running:
guess = int(raw_input('Enter an integer : '))
if guess == number:
print 'Congratulations,you guessed it.'
running = True # this causes the while loop to stop
elif guess < number:
print 'No,it is a little higher than that'
running = True
else:
print 'No,it is a little lower than that'
running = False
else:
print 'The while loop is over.'
# Do anything else you want to do here
print 'Done'