Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.freenet.ag!87.79.20.101.MISMATCH!newsreader4.netcologne.de!news.netcologne.de!novso.com!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.020 X-Spam-Evidence: '*H*': 0.96; '*S*': 0.00; 'else:': 0.03; 'sys': 0.07; 'cc:addr:python-list': 0.11; 'random': 0.14; '"true":': 0.16; 'wrote:': 0.18; 'import': 0.22; 'aug': 0.22; 'cc:addr:python.org': 0.22; 'print': 0.22; 'math': 0.24; 'cc:2**0': 0.24; 'cc:no real name:2**0': 0.24; '>': 0.26; 'pass': 0.26; 'header:In-Reply- To:1': 0.27; 'skip:p 30': 0.29; 'message-id:@mail.gmail.com': 0.30; 'url:mailman': 0.30; 'prints': 0.31; 'url:python': 0.33; 'test': 0.35; 'received:google.com': 0.35; 'url:listinfo': 0.36; 'doing': 0.36; 'url:org': 0.36; 'should': 0.36; 'skip:& 10': 0.38; 'pm,': 0.38; 'skip:& 20': 0.39; 'skip:p 20': 0.39; 'url:mail': 0.40; 'even': 0.60; 'containing': 0.69; 'subject:True': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=o8sQsqag6zFpDaxD48Ywr5akM9esfA4E6LF4atLaLak=; b=niGOrHLumj+o+emu9A2/DbdjuPx4CsXjR8kgTetG/46q8/sdiATmXEjudHEr9pGMr1 LM/KTXImCOQoABHRSly9zAkgVUfEFtHVs2vKaTrz52PotiAulOeqUy1muyEXAt7Je2D2 Az3ZtzX37ZyjlvbG+ky55cKTfwEO3YDN39oWQvm/OTbI9FFBnFWroED2hyaJkdnZL1jw El85gFyG/gIK9/IvphNa0M3DqAcCbpK72XTY3E9tdSl7w/lNxjr5r/vaU7mPpWp0KoTV QwzWLJZ0M9vHq8FjeqERNoFXGUJx8geYETzwsv63MtMYvvirfv9FiAYlv7l98EMMVCa6 85VQ== MIME-Version: 1.0 X-Received: by 10.140.84.138 with SMTP id l10mr9964021qgd.51.1409259460786; Thu, 28 Aug 2014 13:57:40 -0700 (PDT) In-Reply-To: References: Date: Thu, 28 Aug 2014 16:57:40 -0400 Subject: Re: When does True == True From: Joel Goldstick To: Seymore4Head Content-Type: multipart/alternative; boundary=001a11c115a08e81d00501b6c91c Cc: python-list@python.org X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 73 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1409259464 news.xs4all.nl 2829 [2001:888:2000:d::a6]:42753 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:77235 --001a11c115a08e81d00501b6c91c Content-Type: text/plain; charset=UTF-8 On Aug 28, 2014 4:45 PM, "Seymore4Head" wrote: > > import math > import random > import sys > pigword="Razzamattaz" > print ("Pig Latin") > print ("Pick a word containing only alphabetical characters",pigword) > if len(pigword) > 0: > print (pigword) > else: > print ("empty") > if pigword.isalpha() == "True": > print (pigword) > print ("True") > else: > print ("WTF") > print(pigword.isalpha()) > > What am I doing wrong? "True" is not True > > pigword isalpha > the test for true should have passed. > The test for true din't pass even though it prints pigword.isalpha() > True after the else statment. > -- > https://mail.python.org/mailman/listinfo/python-list --001a11c115a08e81d00501b6c91c Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable


On Aug 28, 2014 4:45 PM, "Seymore4Head" <Seymore4Head@hotmail.= invalid> wrote:
>
> import math
> import random
> import sys
> pigword=3D"Razzamattaz"
> print ("Pig Latin")
> print ("Pick a word containing only alphabetical characters"= ,pigword)
> if len(pigword) > 0:
> =C2=A0 =C2=A0 print (pigword)
> else:
> =C2=A0 =C2=A0 print ("empty")
> if pigword.isalpha() =3D=3D "True":
> =C2=A0 =C2=A0 print (pigword)
> =C2=A0 =C2=A0 print ("True")
> else:
> =C2=A0 =C2=A0 print ("WTF")
> print(pigword.isalpha())
>
> What am I doing wrong?
"True" is not True
>
> pigword isalpha
> the test for true should have passed.
> The test for true din't pass even though it prints pigword.isalpha= ()
> True after the else statment.
> --
> https= ://mail.python.org/mailman/listinfo/python-list

--001a11c115a08e81d00501b6c91c--