Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #54453

Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it?

Path csiph.com!usenet.pasdenom.info!news.franciliens.net!news.muarf.org!nntpfeed.proxad.net!proxad.net!feeder1-2.proxad.net!news.tele.dk!news.tele.dk!small.news.tele.dk!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <ian.g.kelly@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.013
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'else:': 0.03; 'elif': 0.05; 'subject:Why': 0.09; 'python': 0.11; "'no',": 0.16; "'yes',": 0.16; 'loop.': 0.16; 'subject: \n ': 0.16; 'subject:run': 0.16; 'subject:under': 0.16; 'subject:when': 0.16; 'true:': 0.16; 'wrote:': 0.18; 'thu,': 0.19; 'thanks.': 0.20; 'this:': 0.26; 'header:In-Reply-To:1': 0.27; 'tried': 0.27; 'statement': 0.30; 'message-id:@mail.gmail.com': 0.30; 'asks': 0.31; 'continues': 0.31; 'sep': 0.31; 'but': 0.35; 'received:google.com': 0.35; 'subject:?': 0.36; 'should': 0.36; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'break': 0.61; 'subject:have': 0.80; 'william': 0.81; 'novice': 0.91; 'old.': 0.93; '2013': 0.98
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=tkwlUbCRYaywssUUs5HSyZy7+PScJFhcImiLKuLdhNE=; b=p/bQiTG5GP18h8BY20x6cEvBEo+6caRJ2PQLrQnJnzdSDspyszbDWl1TT1+yK6M7m5 VtUDM3ieehY2UM4wTgRhSzccb2aOiKgL+QlFUHAAYKuZbaCng0F/+qXHByEAqgBBKFp/ LAH/tzlJgNsEag5+CYdc7FqofFXwzKfacjqzYiVSj5RW2a9/6k021ETEXODD3r8FdcG7 LRcGnLD+Qmaij5ya0xSwen+INM+go6Ftjxc5AWvh7dVPHiyGI2Et8CuvlMjWss9ZmYDA RctvQf0jzgrITwGCarSOj9jmxTQUCgySDqw6IGgd3i6uGvIh2SQNNT0uVJgzSQ626QJJ qRTg==
X-Received by 10.66.234.131 with SMTP id ue3mr5232373pac.35.1379632183758; Thu, 19 Sep 2013 16:09:43 -0700 (PDT)
MIME-Version 1.0
In-Reply-To <CAJsdK=JAY8gSxTyMVN+Ac2u_cwmY2PYwrTyQw1i43tPRJ+ymtw@mail.gmail.com>
References <22b99b0a-598f-4500-9de9-5041c2ce2c8f@googlegroups.com> <CALwzidku1WQ0-+icfE+J8CjVNg4GEH4EF2Pf6cB8nCKyhDAfhQ@mail.gmail.com> <CAJsdK=JAY8gSxTyMVN+Ac2u_cwmY2PYwrTyQw1i43tPRJ+ymtw@mail.gmail.com>
From Ian Kelly <ian.g.kelly@gmail.com>
Date Thu, 19 Sep 2013 17:09:03 -0600
Subject Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it?
To Python <python-list@python.org>
Content-Type text/plain; charset=ISO-8859-1
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.168.1379632193.18130.python-list@python.org> (permalink)
Lines 21
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1379632193 news.xs4all.nl 16010 [2001:888:2000:d::a6]:56337
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:54453

Show key headers only | View raw


On Thu, Sep 19, 2013 at 1:22 PM, William Bryant <gogobebe2@gmail.com> wrote:
> It was the other functions above it. Thanks. but I tried to do the while
> loop - I don't think I did it right, I am novice in python and I am 13 years
> old.

It should be structured like this:

    while True:
        answer = input("Enter yes/no:")
        if answer in ('y', 'yes', 'new list'):
            do_yes_stuff()
            break
        elif answer in ('n', 'no', 'close'):
            do_no_stuff()
            break
        else:
            print("Please enter y or n.")

If they answer 'yes' or 'no', then the break statement breaks out of
the while loop.  Otherwise the while loop continues from the top and
asks them again.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? William Bryant <gogobebe2@gmail.com> - 2013-09-19 11:46 -0700
  Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? John Gordon <gordon@panix.com> - 2013-09-19 18:51 +0000
    Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? patrick vrijlandt <patrick.vrijlandt@gmail.com> - 2013-09-19 19:08 +0000
  Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Ian Kelly <ian.g.kelly@gmail.com> - 2013-09-19 13:01 -0600
  Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Dave Angel <davea@davea.name> - 2013-09-19 20:18 +0000
  Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Ian Kelly <ian.g.kelly@gmail.com> - 2013-09-19 17:09 -0600
    Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? William Bryant <gogobebe2@gmail.com> - 2013-09-20 00:01 -0700
      Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? William Ray Wing <wrw@mac.com> - 2013-09-20 09:04 -0400
      Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Duncan Booth <duncan.booth@invalid.invalid> - 2013-09-20 13:39 +0000
        Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? William Bryant <gogobebe2@gmail.com> - 2013-09-20 22:59 -0700
        Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? William Bryant <gogobebe2@gmail.com> - 2013-09-20 23:07 -0700
          Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2013-09-21 10:25 +0000
          Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Dave Angel <davea@davea.name> - 2013-09-21 12:53 +0000
          Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? MRAB <python@mrabarnett.plus.com> - 2013-09-21 17:18 +0100
          Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? Dave Angel <davea@davea.name> - 2013-09-21 18:09 +0000
      Re: Why does it have red squiggly lines under it if it works perfectly fine and no errors happen when I run it? alex23 <wuwei23@gmail.com> - 2013-09-23 10:39 +1000

csiph-web