while loop - multiple condition

Skip Montanaro skip.montanaro at gmail.com
Mon Oct 13 14:10:09 CEST 2014

On Mon, Oct 13, 2014 at 6:59 AM, Chris Angelico <rosuav at gmail.com> wrote:

> while input('Do you like python?') not in ('yes', 'y'): pass

Unfortunately, you probably have to account for people who SHOUT:

    while input('Do you like python?').lower() not in ('yes', 'y'): pass


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20141013/fab1ec0d/attachment.html>

More information about the Python-list mailing list