Re: [Tutor] Readabilty vs 80 characters

2012-04-20 Thread Peter Otten
Russel Winder wrote: > On Thu, 2012-04-19 at 16:00 +0200, Peter Otten wrote: > [...] >> Seriously, learn that you don't need backslashes if you put the >> expression into parens, precalculate parts of the expression and put them >> into temporary variables -- and if that doesn't suffice to keep th

Re: [Tutor] Readabilty vs 80 characters

2012-04-19 Thread Emile van Sebille
On 4/19/2012 6:29 AM Tino Dai said... Hi! I have a question about style. In PEP-8, it says don't exceed 79 characters, but can this rule ever be trumped by readability? It's trumped by something: >>> for ii in range(10): ... D="*/"*ii+"*.py" ... L=glob.glob(D) ... for pypgm

Re: [Tutor] Readabilty vs 80 characters

2012-04-19 Thread Russel Winder
On Thu, 2012-04-19 at 16:00 +0200, Peter Otten wrote: [...] > Seriously, learn that you don't need backslashes if you put the expression > into parens, precalculate parts of the expression and put them into > temporary variables -- and if that doesn't suffice to keep the code readable > and belo

Re: [Tutor] Readabilty vs 80 characters

2012-04-19 Thread Peter Otten
Tino Dai wrote: > Hi! > > I have a question about style. In PEP-8, it says don't exceed 79 > characters, but can this rule ever be trumped by > readability? > > Eg. > > > if someobject.filter(something) \ > .filter(somethingreallyreallyreallyreallylong == > somethingelserea

Re: [Tutor] Readabilty vs 80 characters

2012-04-19 Thread Evert Rol
On 19 Apr, 2012, at 15:29 , Tino Dai wrote: > Hi! > > I have a question about style. In PEP-8, it says don't exceed 79 > characters, but can this rule ever be trumped by > readability? > Yes, it obviously can. I am a big fan of the 79 character "rule", though. Even with screens and ter

Re: [Tutor] Readabilty vs 80 characters

2012-04-19 Thread Prasad, Ramit
> I have a question about style. In PEP-8, it says don't exceed 79 > characters, but can this rule ever be trumped by > readability? > > Eg. > > > if someobject.filter(something) \ > .filter(somethingreallyreallyreallyreallylong == > somethingelsereallyreallylong) \ >

Re: [Tutor] Readabilty vs 80 characters

2012-04-19 Thread Wayne Werner
On Thu, 19 Apr 2012, Tino Dai wrote: Hi!      I have a question about style. In PEP-8, it says don't exceed 79 characters, but can this rule ever be trumped by  readability? PEP 8 is style guidelines, not hard and fast rules or they wouls be syntax errors. But that would just be annoying, so

[Tutor] Readabilty vs 80 characters

2012-04-19 Thread Tino Dai
Hi! I have a question about style. In PEP-8, it says don't exceed 79 characters, but can this rule ever be trumped by readability? Eg. if someobject.filter(something) \ .filter(somethingreallyreallyreallyreallylong == somethingelsereallyreallylong) \ .filter(otheth