Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.datemas.de!rt.uk.eu.org!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.045 X-Spam-Evidence: '*H*': 0.91; '*S*': 0.00; 'cc:addr:python-list': 0.11; 'jan': 0.12; 'assume': 0.14; 'chained': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'roy': 0.16; 'time.time()': 0.16; 'wrote:': 0.18; 'pointed': 0.19; 'cc:addr:python.org': 0.22; 'delta': 0.24; 'cc:2**0': 0.24; 'header:In-Reply-To:1': 0.27; 'correct': 0.29; 'message- id:@mail.gmail.com': 0.30; 'time:': 0.31; 'fri,': 0.33; "i'd": 0.34; 'received:google.com': 0.35; 'otherwise.': 0.36; 'pm,': 0.38; 'name': 0.63; 'spot': 0.65; 'hints': 0.68; 'smith': 0.68; '3:00': 0.84; 'to:none': 0.92 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:cc :content-type; bh=nKUEae9lWSJTlveRo5h43Wk4bWJ1lGHjj7TGZfGuyOg=; b=W7dQ2sRcaeBnNK7K2TEV8O10aSstS/emRrcnYo7AX6aoN/d3qjIAhNiLJFYZrk9TXr kQ9Iy/HWNoNeWXgOXQhP/dY7yIGxnnG6ZxtgXrghklMA08+K9yBS8kVPLrRgs6UuJQz4 6s9ys/33/XBwxb195gdYNLhwDPcu8r0Ye/etxJ815U0AFzvno3uEHT+UB9yCZoVGrYEn 4jFT2MaPUh/Tfi3Ql1ky+9BKIYpoDNx4+nwcE8puPRxT3jel3wNfmBx19trb7pxiLjoF wDxJJkuCsgdxFNeDgJE0EFK5nYq2gdFXgbLa/aZsL9hxPV+OTYUROSqEnF5DK6kkBOKS f4Yg== MIME-Version: 1.0 X-Received: by 10.68.108.194 with SMTP id hm2mr93151200pbb.22.1388722113375; Thu, 02 Jan 2014 20:08:33 -0800 (PST) In-Reply-To: References: <52C59FF6.5000607@allsup.co> <52c62fa8$0$30001$c3e8da3$5496439d@news.astraweb.com> Date: Fri, 3 Jan 2014 15:08:33 +1100 Subject: Re: Ifs and assignments From: Chris Angelico Cc: "python-list@python.org" Content-Type: text/plain; charset=UTF-8 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: 13 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1388722122 news.xs4all.nl 2901 [2001:888:2000:d::a6]:34285 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:63028 On Fri, Jan 3, 2014 at 3:00 PM, Roy Smith wrote: > I do this all the time: > > t0 = time.time() > [some code] > t1 = time.time() > dt = t1 = t0 # <-- spot the typo? Yep, I see that... now that it's pointed out as a typo. Without the marker, I'd assume it's correct chained assignment, and only an examination of the name (dt = delta t) hints otherwise. ChrisA