Are you using Python 3? The <> operator in Python 2 is considered bad form, and was removed in Python 3. Use != instead.
Join the #python-forum IRC channel on irc.freenode.net for off-topic chat!
Please prefer not to PM members. The point of the forum is so that anyone can benefit. We don't want to help you over PMs/emails/Skype chats that others can't benefit from