To: Steven D'Aprano
From: "Stefan Ram"
To: Steven D'Aprano
From: r...@zedat.fu-berlin.de (Stefan Ram)
Steven D'Aprano writes:
>It has been a long, long time since Python has been a "simple" language
>suitable for rank beginners, if it ever was. Py
To: Stefan Ram
From: r...@zedat.fu-berlin.de (Stefan Ram)
r...@zedat.fu-berlin.de (Stefan Ram) writes:
>Still, one must not forget that learning Python encompasses
>all the hard work it takes to learn how to program in every
>language.
"Beginner", however, is a very
To: Richard Damon
From: "Stefan Ram"
To: Richard Damon
From: r...@zedat.fu-berlin.de (Stefan Ram)
Richard Damon writes:
>Now, if I have a parser that doesn't use the locale, but some other rule
>base than I just need to provide it with the right rules, which is
>bas
To: Stefan Ram
From: "Stefan Ram"
To: Stefan Ram
From: r...@zedat.fu-berlin.de (Stefan Ram)
r...@zedat.fu-berlin.de (Stefan Ram) writes:
>def f():
>def g():
>g.x += 1
>return g.x
>g.x = 0
>return g
Or, "for all g to sha
To: Steven D'Aprano
From: "Stefan Ram"
To: Steven D'Aprano
From: r...@zedat.fu-berlin.de (Stefan Ram)
Steven D'Aprano writes:
>def f():
>static x = 0
>def g():
>x += 1
>return x
>return g
What one can do today:
ma
To: Steven D'Aprano
From: r...@zedat.fu-berlin.de (Stefan Ram)
Steven D'Aprano writes:
>It has been a long, long time since Python has been a "simple" language
>suitable for rank beginners, if it ever was. Python is not Scratch.
Python is simpler insofar as you c
To: Richard Damon
From: r...@zedat.fu-berlin.de (Stefan Ram)
Richard Damon writes:
>Now, if I have a parser that doesn't use the locale, but some other rule
>base than I just need to provide it with the right rules, which is
>basically just defining the right locale.
Here&
To: Steven D'Aprano
From: r...@zedat.fu-berlin.de (Stefan Ram)
Steven D'Aprano writes:
>def f():
>static x = 0
>def g():
>x += 1
>return x
>return g
What one can do today:
main.py
def g():
g.x += 1
return g.x
g.x = 0
pri
To: Stefan Ram
From: r...@zedat.fu-berlin.de (Stefan Ram)
r...@zedat.fu-berlin.de (Stefan Ram) writes:
>def f():
>def g():
>g.x += 1
>return g.x
>g.x = 0
>return g
Or, "for all g to share the same x":
main.py
def f():
Cai Gengyang writes:
Statement 0:
>count = 0
Statement 1:
>if count < 5:
> print "Hello, I am an if statement and count is", count
Statement 2:
>while count < 10:
> print "Hello, I am a while and count is", count
> count += 1
There are three statements here.
They are executed
Ram) (Stefan Ram)
Greg Tibbet writes:
>I'm an old timer, have programmed in Fortran, C, C++, Perl, and a bit
>of Java and trying to learn this new-fangled Python language!
Which actually is older than Java.
>def ellipse(self, xy, fill=None, outline=None):
>&
r...@zedat.fu-berlin.de (Stefan Ram) writes:
>Then you can use pickle or custom methods to save and
>restore the object, or get the state from an iterator
>and create a new iterator with that state later.
One does not always have to write a custom class,
for example:
main.py
impo
Greg Tibbet writes:
>I'm an old timer, have programmed in Fortran, C, C++, Perl, and a bit
>of Java and trying to learn this new-fangled Python language!
Which actually is older than Java.
>def ellipse(self, xy, fill=None, outline=None):
>"""Draw an ellipse."""
>ink, fill = sel
r...@zedat.fu-berlin.de (Stefan Ram) writes:
>Then you can use pickle or custom methods to save and
>restore the object, or get the state from an iterator
>and create a new iterator with that state later.
One does not always have to write a custom class,
for example:
main.py
impo
Greg Tibbet writes:
>I'm an old timer, have programmed in Fortran, C, C++, Perl, and a bit
>of Java and trying to learn this new-fangled Python language!
Which actually is older than Java.
>def ellipse(self, xy, fill=None, outline=None):
>"""Draw an ellipse."""
>ink, fill = sel
15 matches
Mail list logo