Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!weretis.net!feeder1.news.weretis.net!feeder.erje.net!newsfeed.xs4all.nl!newsfeed6.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.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'ascii': 0.07; 'received:verizon.net': 0.07; 'terry': 0.07; 'coarse': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:80.91.229.12': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'received:lo.gmane.org': 0.09; 'am,': 0.12; 'subject:was': 0.15; '(read': 0.16; '42,': 0.16; 'kern': 0.16; 'reedy': 0.16; 'subject: \n ': 0.16; 'subject:syntax': 0.16; 'wrote:': 0.18; '>>>': 0.18; 'jan': 0.19; '(which': 0.19; 'written': 0.20; 'subject:not': 0.21; 'dec': 0.22; 'header:In- Reply-To:1': 0.22; 'horizontal': 0.23; 'skip:= 10': 0.28; 'pm,': 0.29; 'lines': 0.30; 'equivalent.': 0.30; 'relation': 0.30; 'chris': 0.30; 'thu,': 0.32; 'programmers': 0.32; 'subject:]': 0.32; 'header:User-Agent:1': 0.33; 'header:X-Complaints-To:1': 0.33; 'to:addr:python-list': 0.34; 'symbol': 0.34; 'record': 0.35; 'think': 0.37; 'using': 0.38; 'received:org': 0.38; 'should': 0.39; 'to:addr:python.org': 0.40; 'might': 0.40; 'more': 0.61; '2011': 0.61; 'taught': 0.71; 'rusi': 0.84 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Terry Reedy Subject: Re: % is not an operator [was Re: Verbose and flexible args and kwargs syntax] Date: Thu, 15 Dec 2011 18:15:01 -0500 References: <4ee81592$0$11091$c3e8da3@news.astraweb.com> <4ee89762$0$29979$c3e8da3$5496439d@news.astraweb.com> <4f2f6742-b1b2-4605-8004-b6aa431b8513@k5g2000pra.googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: pool-74-109-121-73.phlapa.fios.verizon.net User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20111105 Thunderbird/8.0 In-Reply-To: <4f2f6742-b1b2-4605-8004-b6aa431b8513@k5g2000pra.googlegroups.com> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 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: 32 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1323990921 news.xs4all.nl 6922 [2001:888:2000:d::a6]:47389 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:17319 On 12/15/2011 6:04 AM, rusi wrote: > On Dec 15, 3:58 pm, Chris Angelico wrote: >> On Thu, Dec 15, 2011 at 9:47 PM, Robert Kern wrote: >>> 42 = 2 mod 5 >>> 2 = 42 mod 5 >> >> It might make more sense to programmers if you think of it as written: >> >> 42 = 2, mod 5 >> 2 = 42, mod 5 Better, using ascii text, would be 42 =mod5 2 where =mod is a parameterized equivalence relation that is coarser than = (which is =mod-infinity). divmod(a,inf) = 0,a. =mod1 is the most coarse relation in that it make every count equivalent. divmod(a,1) = a,1. > For the record I should say that the guy who taught me abstract > algebra, said about as much: > He said that the notation > a == b mod n > should be written as > a ==n b > (read the == as 3 horizontal lines and the n as a subscript) The 3 horizontal line symbol is often used for equivalence relations other than =. -- Terry Jan Reedy