Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news.szaf.org!feedme.news.telefonica.de!telefonica.de!diesel.cu.mi.it!.POSTED!not-for-mail From: giacomo boffi Newsgroups: comp.lang.python Subject: Re: while loop - multiple condition Date: Wed, 15 Oct 2014 01:04:42 +0200 Organization: The Sun and the Rain. Lines: 15 Message-ID: <87oatel0c5.fsf@pascolo.net> References: <878uklcd3r.fsf@elektro.pacujo.net> NNTP-Posting-Host: ppp-30-13.21-151.libero.it Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: virtdiesel.mng.cu.mi.it 1413327883 25777 151.21.13.30 (14 Oct 2014 23:04:43 GMT) X-Complaints-To: abuse@diesel.cu.mi.it NNTP-Posting-Date: Tue, 14 Oct 2014 23:04:43 +0000 (UTC) User-Agent: Gnus/5.101 (Gnus v5.10.10) XEmacs/21.5-b34 (linux) Cancel-Lock: sha1:MDGNAl63jVABrknxOdgtcH0sGXw= Xref: csiph.com comp.lang.python:79122 Tim Chase writes: > On 2014-10-12 22:16, Marko Rauhamaa wrote: >> is equivalent with >> >> while ans.lower()[0] != 'y': >> ans = input('Do you like python?') > > And still better improved with > > while ans[:1].lower() != 'y': > ans = input('Do you like python?') yok is Turkish for an EMPHATIC NO (or, at least, that's what I was led to think many years ago)