Path: csiph.com!eternal-september.org!feeder.eternal-september.org!border1.nntp.ams1.giganews.com!nntp.giganews.com!newsfeed.xs4all.nl!newsfeed7.news.xs4all.nl!nzpost1.xs4all.net!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: UNSURE 0.293 X-Spam-Level: ** X-Spam-Evidence: '*H*': 0.47; '*S*': 0.06; 'thu,': 0.15; 'wrote:': 0.16; "wouldn't": 0.16; '2015': 0.20; 'suggested': 0.20; 'latter': 0.22; 'referring': 0.22; 'slightly': 0.23; 'header:In-Reply-To:1': 0.24; 'message-id:@mail.gmail.com': 0.27; 'received:google.com': 0.35; 'but': 0.36; "wasn't": 0.36; 'to:addr:python-list': 0.36; 'pm,': 0.36; 'subject:: ': 0.37; 'mean': 0.38; 'takes': 0.39; 'to:addr:python.org': 0.40; 'john': 0.61; 'skip:u 10': 0.61; 'course': 0.62; 'more': 0.63; 'places': 0.64; 'between': 0.65; 'commenting': 0.84; 'subject:value': 0.84; 'to:name:python': 0.84; 'subject:Check': 0.95 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=1QCW9cRoJDkWTCI0e4L56NJ7OZ/r7AsUMTkk0cbu8J4=; b=qRLPUyr8vq9fehs/+qNE7wWI9OZldiMRFcZ5CG95jPRSB3CDe835JKL9lXNWBP7EvY 36hAHx/30q2drSRY2SjnAahLLx//6h86/b+MXThJUi3K1NGqjpE16C8xMJ85xWGFdrQc yMuUBQP5wgGmcoUNigQkFitwYMC3QJDTurhzhOFF/xVDRa8yqoTz2pXTzSyB9DIJySmy si4B28i/TDyMOE8+F1fDk1ekFAOGUD0zx92vL1vCRSmePk6g/spimhQ7lsL+ce8WRbFX xl1wVYAjpD3LPDHTZtms5vvjTce0AxSQw37kOlMYuPYtyKSHovUr8LQCD38tSk7bNeiW RzUA== X-Received: by 10.107.14.196 with SMTP id 187mr15526816ioo.11.1443736917268; Thu, 01 Oct 2015 15:01:57 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: <560d78e2$0$1618$c3e8da3$5496439d@news.astraweb.com> <560d8726$0$1602$c3e8da3$5496439d@news.astraweb.com> <87r3le1ht3.fsf@elektro.pacujo.net> From: Ian Kelly Date: Thu, 1 Oct 2015 16:01:17 -0600 Subject: Re: Check if a given value is out of certain range To: Python Content-Type: text/plain; charset=UTF-8 X-Mailman-Approved-At: Fri, 02 Oct 2015 09:09:30 +0200 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.20+ 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: 25 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1443769771 news.xs4all.nl 23802 [2001:888:2000:d::a6]:49005 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:97326 On Thu, Oct 1, 2015 at 3:45 PM, John Gordon wrote: > In <87r3le1ht3.fsf@elektro.pacujo.net> Marko Rauhamaa writes: > >> > I wasn't commenting directly to the "ask not..." quote; I was >> > referring upthread to the choice between >> > >> > not 0 <= x <= 10 >> > >> > and >> > >> > x < 0 or x > 10 >> > >> > Both are of course understandable, but in my opinion, the latter one >> > takes slightly less effort to grok. > >> Wouldn't > >> x < 0 or 10 < x > >> be even more visual? > > I don't know what you mean by "more visual". Visually, it places the x outside the range suggested by 0 and 10, similarly to how 0 <= x <= 10 places the x inside.