In article mailman.10041.1400164039.18130.python-l...@python.org,
Chris Angelico ros...@gmail.com wrote:
On Fri, May 16, 2014 at 12:17 AM, wxjmfa...@gmail.com wrote:
One another trick is to drop spaces around keywords
9and 12345or 99if 'a'in'a' else or 77
12345
and
On Sat, May 17, 2014 at 10:52 PM, Albert van der Horst
alb...@spenarnc.xs4all.nl wrote:
That may be tong-in-cheek but mathematicians do exactly that. We
use roman, greek and hebrew alphabets in normal italics and boldface
and then some special characters for element-of, logical-or, integral
On 2014-05-17 12:52, Albert van der Horst wrote:
Now translate E=mc^2 into Java.
I suspect it would be something like
public class Einstein {
private double mass=0, energy=0;
public class Relativity implements IEquation {
Relativity(double mass) {
set_mass(mass);
}
public
In article mailman.10085.140038.18130.python-l...@python.org,
Tim Chase python.l...@tim.thechases.com wrote:
On 2014-05-17 12:52, Albert van der Horst wrote:
Now translate E=mc^2 into Java.
I suspect it would be something like
public class Einstein {
private double mass=0,
In article mailman.10083.1400332708.18130.python-l...@python.org,
Chris Angelico ros...@gmail.com wrote:
On Sat, May 17, 2014 at 10:52 PM, Albert van der Horst
alb...@spenarnc.xs4all.nl wrote:
That may be tong-in-cheek but mathematicians do exactly that. We
use roman, greek and hebrew
On 17/05/2014 13:52, Albert van der Horst wrote:
Now translate E=mc^2 into Java.
I can't do that as I simply don't understand it. What has the
Marylebone Cricket Club got to do with E?
--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our
In article mailman.10088.1400335366.18130.python-l...@python.org,
Mark Lawrence breamore...@yahoo.co.uk wrote:
On 17/05/2014 13:52, Albert van der Horst wrote:
Now translate E=mc^2 into Java.
I can't do that as I simply don't understand it. What has the
Marylebone Cricket Club got
On 17/05/2014 15:06, Roy Smith wrote:
In article mailman.10088.1400335366.18130.python-l...@python.org,
Mark Lawrence breamore...@yahoo.co.uk wrote:
On 17/05/2014 13:52, Albert van der Horst wrote:
Now translate E=mc^2 into Java.
I can't do that as I simply don't understand it. What
On Saturday, May 17, 2014 7:36:19 PM UTC+5:30, Roy Smith wrote:
Mark Lawrence wrote:
Now translate E=mc^2 into Java.
I can't do that as I simply don't understand it. What has the
Marylebone Cricket Club got to do with E?
A wicket looks like an E on its side. Does that help?
Rustom Mody rustompm...@gmail.com writes:
You said this:
The 80 character line limit is *not* driven by a limitation of
computer technology; it is driven by a limitation of human
cognition. For that reason, it remains relevant until human
cognition in the general reading population
On Thu, 15 May 2014 17:12:57 +0300, Marko Rauhamaa wrote:
A definitive Python source file could be binary, XML, .py, .ast,
whatever,
Containing *what*? You can't just wave your hands and say binary. What
sort of binary file? Perhaps a JPEG file, where red triangles of
different sizes
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info writes:
Source code is, *by definition*, the definitive version. (It's the
SOURCE, see?) Zipping the source code just means that the *source*
inside the zip file is the definitive version, not the compressed
binary data.
I find the Free
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info:
On Thu, 15 May 2014 17:12:57 +0300, Marko Rauhamaa wrote:
A definitive Python source file could be binary, XML, .py, .ast,
whatever,
Containing *what*? You can't just wave your hands and say binary.
I sure can and am.
Besides, where
On Thu, 15 May 2014 17:06:13 -0700, Rustom Mody wrote:
The claim being made is that 79/80 is a fundamental, cognitive limit and
has no relation to technological changes.
I don't believe anyone has made that claim. You are reading a statement
about general (typical, average) behaviour, and
On Fri, May 16, 2014 at 4:25 PM, Steven D'Aprano
steve+comp.lang.pyt...@pearwood.info wrote:
Containing *what*? You can't just wave your hands and say binary. What
sort of binary file? Perhaps a JPEG file, where red triangles of
different sizes represent keywords. Variable names can be encoded
On Fri, May 16, 2014 at 5:00 PM, Marko Rauhamaa ma...@pacujo.net wrote:
Well, actually, any .py file *does* specify a unique AST. Nothing would
prevent the text editor from presenting it according to your
preferences. They all do that to a degree anyway (colors, fonts), but
they could take
Chris Angelico ros...@gmail.com:
You still haven't answered my biggest objection from earlier. Source
code contains more information than the AST does; even if you make a
frAnkenSTein's monster that includes comments, there's still the point
that whitespace carries information, and that
On Fri, May 16, 2014 at 7:18 PM, Marko Rauhamaa ma...@pacujo.net wrote:
If every bit of your Python text conveys information, obviously, it
can't be abstracted. I don't believe that to be the case, though. So
this AST should contain all *actual* information worth conveying and
strip away
Chris Angelico ros...@gmail.com:
Compare these two assignment statements:
area = (base*base + extension*extension
+ annex*annex + (annex-extension)*annex
+ triangle*triangle/2
+ circle*circle*math.PI + sphere*sphere*4*math.PI)
area = (base*base + extension*extension +
On 05/14/2014 10:12 PM, Roy Smith wrote:
In article mailman.10026.1400116640.18130.python-l...@python.org,
Mark Lawrence breamore...@yahoo.co.uk wrote:
I still remember the cry of anguish when the guy in the computer
building at (the then) Portsmouth Polytechnic dropped his cardboard box
of
On 15.05.2014 04:43, Ben Finney wrote:
Rustom Mody rustompm...@gmail.com writes:
Until then may we relegate '79' to quaint historical curiosities
Not until the general capacity of human cognition advances to make
longer lines easier to read.
I find it surprising how you can make such a
Johannes Bauer dfnsonfsdu...@gmx.de:
I don't know why anyone would force a display issue onto everyone.
Well, if I have to work with your code, you are forcing your style on
me.
It imples the arrogant stance that every human being has the exact way
of reading and writing code. Everyone can
On Thu, May 15, 2014 at 10:32 PM, Johannes Bauer dfnsonfsdu...@gmx.de wrote:
Personally I find overly narrow code (80 cols) to be much *harder* to
read than code that is 100 cols wide. Keep in mind that even if the
break is at 100 cols, lines will rarely exceed that limit. And if they
do to
On Thu, May 15, 2014 at 11:07 PM, Marko Rauhamaa ma...@pacujo.net wrote:
I know the idea of windows is fast disappearing from modern
(mobile) computing; you have apps instead that commandeer the whole
screen. Personally, I find that a big step backwards. I want to be able
to subdivide the
On Thu, 15 May 2014 23:31:44 +1000, Chris Angelico wrote:
The Windows 8 / Unity / GNOME 3 model annoys me greatly. Can't get work
done like that.
ChrisA
Windows 8/ Unity/ Gnome 3 are great on tablets (at least they look like
they should be the only one I can confirm is Win 8) but lousy on a
On Thu, May 15, 2014 at 11:38 PM, alister
alister.nospam.w...@ntlworld.com wrote:
On Thu, 15 May 2014 23:31:44 +1000, Chris Angelico wrote:
The Windows 8 / Unity / GNOME 3 model annoys me greatly. Can't get work
done like that.
ChrisA
Windows 8/ Unity/ Gnome 3 are great on tablets (at least
On Thursday, May 15, 2014 6:37:54 PM UTC+5:30, Marko Rauhamaa wrote:
Johannes Bauer :
I don't know why anyone would force a display issue onto everyone.
Well, if I have to work with your code, you are forcing your style on
me.
It imples the arrogant stance that every human being
In article 78ac407a-c429-4a7a-93c9-5d83e0f09...@googlegroups.com,
Rustom Mody rustompm...@gmail.com wrote:
And yet programmers continue to be decades behind all other users of
computers. We continue to use flat text for our programs when all others
have moved on.
It's not like we haven't
On Thursday, May 15, 2014 6:57:26 PM UTC+5:30, Chris Angelico wrote:
The limit of human readability is generally given to be somewhere in
the range of 60-120. It's not a single specific value that's exactly
the same for everyone; personally, I like my lines of code to be a bit
longer than 80,
On Thu, May 15, 2014 at 11:58 PM, Roy Smith r...@panix.com wrote:
There *are* some places where non-text programming has won. The biggest
example would be GUI builders. Nobody programs screen and window
layouts by typing textual descriptions. They push boxes around in a GUI
builder.
Hi,
Rustom Mody rustompm...@gmail.com:
We continue to use flat text for our programs when all others have
moved on.
My more moderate and immediate point is, why should the physical
encoding of the program be also the presentation format?
A definitive Python source file could be binary, XML, .py,
On Thursday, May 15, 2014 7:28:01 PM UTC+5:30, Roy Smith wrote:
Rustom Mody wrote:
And yet programmers continue to be decades behind all other users of
computers. We continue to use flat text for our programs when all others
have moved on.
It's not like we haven't tried.
Le mardi 13 mai 2014 10:45:49 UTC+2, Peter Otten a écrit :
Ganesh Pal wrote:
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed maximum line Length
of 79./80 characters
Example 1 :
On Fri, May 16, 2014 at 12:12 AM, Marko Rauhamaa ma...@pacujo.net wrote:
A definitive Python source file could be binary, XML, .py, .ast,
whatever, and that would also be the file fed to the Python
compiler/interpreter. However, your editor could choose freely how to
present it to you.
IOW,
Rustom Mody rustompm...@gmail.com:
And yet you routinely find people on this list recommending writing
python to using a GUI-builder. On the one hand I am tempted to say
Sheesh!! On the other, maybe the builders are still too
half-assed... Dunno
That's like diagnosing cancer without invasive
On Fri, May 16, 2014 at 12:17 AM, wxjmfa...@gmail.com wrote:
One another trick is to drop spaces around keywords
9and 12345or 99if 'a'in'a' else or 77
12345
and pray, the tools from those who are wasting their time in
writing code analyzers or syntax colorizers or
On Thu, May 15, 2014 at 9:29 AM, Marko Rauhamaa ma...@pacujo.net wrote:
Who of you hasn't sworn at a Web editor that gets the formatting all
messed up when you have typed a backspace in the wrong place?
My current pet peeve is the Gmail composition pane. What a load of
crap (especially in rich
Chris Angelico ros...@gmail.com:
I believe the Python interpreter happily accepts a zip file, which in
theory could be edited directly by a competent text editor. But that
has nothing to do with PEP 8. Compare a classic compiled language like
C - you have the bit you edit (the C source code)
On Fri, May 16, 2014 at 12:29 AM, Marko Rauhamaa ma...@pacujo.net wrote:
An everyday example: a word processor displays the word hello with
hel in boldface and lo in italics. You put the cursor between the
l's and type a letter. Should it be in boldface or italics?
Impossible to say, and one
On Fri, May 16, 2014 at 12:36 AM, Marko Rauhamaa ma...@pacujo.net wrote:
You and I could have opened the same C file. Only you see:
#include stdio.h
int ++
main ( int argc, | My first C program |
Le jeudi 15 mai 2014 16:27:16 UTC+2, Chris Angelico a écrit :
On Fri, May 16, 2014 at 12:17 AM, wxjmfa...@gmail.com wrote:
One another trick is to drop spaces around keywords
9and 12345or 99if 'a'in'a' else or 77
12345
and pray, the tools from
On 15/05/2014 14:58, Roy Smith wrote:
In article 78ac407a-c429-4a7a-93c9-5d83e0f09...@googlegroups.com,
Rustom Mody rustompm...@gmail.com wrote:
And yet programmers continue to be decades behind all other users of
computers. We continue to use flat text for our programs when all others
have
On Thu, 15 May 2014 23:44:34 +1000, Chris Angelico wrote:
On Thu, May 15, 2014 at 11:38 PM, alister
alister.nospam.w...@ntlworld.com wrote:
On Thu, 15 May 2014 23:31:44 +1000, Chris Angelico wrote:
The Windows 8 / Unity / GNOME 3 model annoys me greatly. Can't get
work done like that.
On 5/15/2014 10:42 AM, Chris Angelico wrote:
Impossible to say, and one of the perpetual annoyances. Here's a web
site that I host:
http://gilbertandsullivan.org.au/index.php?option=com_contentview=articleid=92:2001-patiencecatid=30:patienceItemid=102
(Tiny URL: http://tinyurl.com/pphpkuk )
On 5/15/2014 9:58 AM, Rustom Mody wrote:
As far as I can see the votaries of the mystical 79 have yet to explain
how/where it appeared from
As has been explained before, and is implied in the PEP, 79 = 80 - 1.
80 chars - 1 character width cursor leaves 79 non-cursor characters.
When enter is
Johannes Bauer dfnsonfsdu...@gmx.de writes:
On 15.05.2014 04:43, Ben Finney wrote:
Rustom Mody rustompm...@gmail.com writes:
Until then may we relegate '79' to quaint historical curiosities
Not until the general capacity of human cognition advances to make
longer lines easier to
On 2014-05-15 22:50, Terry Reedy wrote:
On 5/15/2014 10:42 AM, Chris Angelico wrote:
Impossible to say, and one of the perpetual annoyances. Here's a web
site that I host:
http://gilbertandsullivan.org.au/index.php?option=com_contentview=articleid=92:2001-patiencecatid=30:patienceItemid=102
On Friday, May 16, 2014 3:51:27 AM UTC+5:30, Terry Reedy wrote:
On 5/15/2014 9:58 AM, Rustom Mody wrote:
As far as I can see the votaries of the mystical 79 have yet to explain
how/where it appeared from
As has been explained before, and is implied in the PEP, 79 = 80 - 1.
80
Rustom Mody rustompm...@gmail.com writes:
The claim being made is that 79/80 is a fundamental, cognitive limit
and has no relation to technological changes.
Who has made that claim, and where? You appear to be attacking a straw
man.
Rather, I've claimed that the conventional lime length limit
On Thu, 15 May 2014 16:07:54 +0300, Marko Rauhamaa wrote:
Johannes Bauer dfnsonfsdu...@gmx.de:
I don't know why anyone would force a display issue onto everyone.
Well, if I have to work with your code, you are forcing your style on
me.
+1
It imples the arrogant stance that every human
On Thu, 15 May 2014 06:58:53 -0700, Rustom Mody wrote:
As far as I can see the votaries of the mystical 79 have yet to explain
how/where it appeared from
You're either trolling, or haven't been reading this thread in any
detail. That's already been explained, repeatedly both in this thread
On Friday, May 16, 2014 5:51:21 AM UTC+5:30, Ben Finney wrote:
Rather, I've claimed that the conventional lime length limit is *based
in* the real cognitive limits of human reading comprehension -- and that
technologies have been designed with corresponding limitations.
Nowhere have I
On 5/13/2014 6:55 PM, Ben Finney wrote:
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info writes:
On Tue, 13 May 2014 04:52:26 -0700, Rustom Mody wrote:
What this goes to show is that while 80 is ridiculously low by most
displays today,
Not for people who like to has two (or three, or
In article a3253d6a-ef89-49d5-b866-8c06a7462...@googlegroups.com,
Rustom Mody rustompm...@gmail.com wrote:
On Tuesday, May 13, 2014 12:37:24 PM UTC+5:30, Ganesh Pal wrote:
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed
On 05/14/2014 03:53 PM, Albert van der Horst wrote:
In article a3253d6a-ef89-49d5-b866-8c06a7462...@googlegroups.com,
Rustom Mody rustompm...@gmail.com wrote:
On Tuesday, May 13, 2014 12:37:24 PM UTC+5:30, Ganesh Pal wrote:
Hi Team ,
what would be the best way to intent the below line .
I
On 15/05/2014 01:15, Gary Herron wrote:
Which is a relic of the even older punch cards which contained one line
of (up to) 80 characters.
Gary Herron
I still remember the cry of anguish when the guy in the computer
building at (the then) Portsmouth Polytechnic dropped his cardboard box
of
In article mailman.10026.1400116640.18130.python-l...@python.org,
Mark Lawrence breamore...@yahoo.co.uk wrote:
I still remember the cry of anguish when the guy in the computer
building at (the then) Portsmouth Polytechnic dropped his cardboard box
of punch cards that made up his end of
On Thursday, May 15, 2014 4:23:52 AM UTC+5:30, Albert van der Horst wrote:
Rustom Mody wrote:
80-character limit?!
Sheesh! A relic of the days when terminals were ASCII and 80x24
80 character was the hard limit.
The soft limit for readability is 60..65 characters.
Think about it.
Rustom Mody rustompm...@gmail.com writes:
Until then may we relegate '79' to quaint historical curiosities
Not until the general capacity of human cognition advances to make
longer lines easier to read.
We humans may be historical curiosities some day; until then, let's
continue to write our
On Wed, 14 May 2014 19:36:13 -0700, Rustom Mody wrote:
And there are (semi)hard technological limits like if you post code
longer 65 chars out here it will fold at random unforeseen points. These
limits get irrelevant as the technology changes.
The technological limits may become irrelevant,
On 15/05/2014 03:43, Ben Finney wrote:
Rustom Mody rustompm...@gmail.com writes:
Until then may we relegate '79' to quaint historical curiosities
Not until the general capacity of human cognition advances to make
longer lines easier to read.
We humans may be historical curiosities some day;
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed maximum line Length of
79./80 characters
Example 1 :
p =
Subprocess.Popen(shlex.split(cmd),stdout=subprocess.PIPE,stderr=subprocess.PIPE)
Iam running pylint and it says
Ganesh Pal wrote:
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed maximum line Length
of 79./80 characters
Example 1 :
p =
Subprocess.Popen(shlex.split(cmd),stdout=subprocess.PIPE,stderr=subprocess.PIPE)
On Tue, 13 May 2014 10:45:49 +0200, Peter Otten wrote:
Ganesh Pal wrote:
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed maximum line
Length of 79./80 characters
Example 1 :
p =
On Tuesday, May 13, 2014 12:37:24 PM UTC+5:30, Ganesh Pal wrote:
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed maximum line Length of
79./80 characters
Example 1 :
p =
In article mailman.9945.1399965443.18130.python-l...@python.org,
Ganesh Pal ganesh1...@gmail.com wrote:
Hi Team ,
what would be the best way to intent the below line .
I have few lines in my program exceeding the allowed maximum line Length of
79./80 characters
Example 1 :
p
Ganesh Pal ganesh1...@gmail.com writes:
what would be the best way to intent the below line .
You'd need to define “best” in order to get an objective answer.
So my answer will be based on my preferences, and general rules I've
observed for making code readable.
Example 1 :
p =
Roy Smith r...@panix.com writes:
p = Subprocess.Popen(shlex.split(cmd),
stdout=subprocess.PIPE,
stderr=subprocess.PIPE)
That is PEP 8 conformant, but I find it hurts maintainability: it is far
too much indentation. Horizontal space is
On 2014-05-13 22:26, Ben Finney wrote:
Changing the name on the first line doesn't entail changing any
other line::
proc = Subprocess.Popen(
shlex.split(cmd),
stdout=subprocess.PIPE,
stderr=subprocess.PIPE)
special_process_map[this_process] =
On Tuesday, May 13, 2014 2:15:49 PM UTC+5:30, Peter Otten wrote:
Ganesh Pal wrote:
what would be the best way to intent the below line .
p =
Subprocess.Popen(shlex.split(cmd),stdout=subprocess.PIPE,stderr=subprocess.PIPE)
(3) Import names:
from subprocess import PIPE
p =
On Tue, 13 May 2014 04:52:26 -0700, Rustom Mody wrote:
What this goes to show is that while 80 is ridiculously low by most
displays today,
Not for people who like to has two (or three, or four) windows side-by-
side. Or multiple views of the same document.
it is too high for many
Steven D'Aprano steve+comp.lang.pyt...@pearwood.info writes:
On Tue, 13 May 2014 04:52:26 -0700, Rustom Mody wrote:
What this goes to show is that while 80 is ridiculously low by most
displays today,
Not for people who like to has two (or three, or four) windows side-by-
side. Or
Ben Finney wrote:
The 80 character line limit is *not* driven by a limitation of computer
technology; it is driven by a limitation of human cognition. For that
reason, it remains relevant until human cognition in the general reading
population improves.
Another thing: Just because I may have
In article mailman.9961.1399984013.18130.python-l...@python.org,
Ben Finney b...@benfinney.id.au wrote:
Roy Smith r...@panix.com writes:
p = Subprocess.Popen(shlex.split(cmd),
stdout=subprocess.PIPE,
stderr=subprocess.PIPE)
That
74 matches
Mail list logo