Is there any Built-in function to check whether  a character is an ASCII 
character?

I am trying to learn event driven programming in python. Heres my code:

while 1:
    key=msvcrt.getch()
    if key==255:
        continue
    else:
        print "the key is ", key


But the output is:-

the key is  ÿ
the key is  ÿ
the key is  ÿ
the key is  ÿ
the key is  ÿ
the key is  ÿ
the key is  ÿ
the key is  ÿ(infinite loop)

Why is this happening ? what is the  ÿ character?





 
---------------------------------
Now that's room service! Choose from over 150,000 hotels 
in 45,000 destinations on Yahoo! Travel to find your fit.
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to