i have the following python script:
import sys 
text = ""
while 1:
    while 1:
       c = sys.stdin.read(1)
       text = text + c
       if c == '\n':
           break
    print("Input: %s" % text)
    print (text)
    print ( text == 'Exit')
    print(text)
    if(text is "Exit"):
        print('you have exited')
        break
    text = ''
The intent is to keep on printing words which user inputs, till the word he inputs is 'Exit'. But when i enter the word 'Exit' it doesn't break out of the outer while loop. Any idea why?
 
    