On Dec 12, 7:03 pm, Paul Rudin <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] writes:
> > On Dec 12, 5:51 pm, Paul Rudin <[EMAIL PROTECTED]> wrote:
> >> [EMAIL PROTECTED] writes:
> >> > I don't understand what I don't understand in the following:
>
> >> I haven't tried to understand what your code
[EMAIL PROTECTED] a écrit :
> Thanks to all!
>
> I will put my class defs first (tho not without expressing my
> disappointment that this is required in a late 20th century language);
That's because you dont get the "execution model" of Python.
First point, remember that Python in Python everyth
On Wed, 2007-12-12 at 12:48 -0800, [EMAIL PROTECTED] wrote:
> Thanks to all!
>
> I will put my class defs first (tho not without expressing my
> disappointment that this is required in a late 20th century language);
You don't have to physically *put* class definitions first in your code.
What mat
Thanks to all!
I will put my class defs first (tho not without expressing my
disappointment that this is required in a late 20th century language);
learn about enumerate as it looks like exactly what I need and discard
my C++/Java based object model because this is a totally other thing.
If someo
[EMAIL PROTECTED] writes:
> On Dec 12, 5:51 pm, Paul Rudin <[EMAIL PROTECTED]> wrote:
>> [EMAIL PROTECTED] writes:
>> > I don't understand what I don't understand in the following:
>>
>> I haven't tried to understand what your code is doing - but the
>> NameError arises because you try to use Loc
<[EMAIL PROTECTED]> wrote:
>I don't understand what I don't understand in the following:
> [ ... ]
You've already got an answer as to what's causing your name error.
But that's not your only problem. It looks like you need an
introduction to enumerate():
for line_ptr, text in enumerate(file('sam
[EMAIL PROTECTED] a écrit :
> I don't understand what I don't understand in the following:
You already have the answer (hint: a Python module is sequentially
executed when loaded by the interpreter)
Just a couple side notes:
> # but I need locations, so this is impure, 11-line, Python:
>
> l
On Dec 12, 5:51 pm, Paul Rudin <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] writes:
> > I don't understand what I don't understand in the following:
>
> I haven't tried to understand what your code is doing - but the
> NameError arises because you try to use Loc before its definition. Put
> the d
[EMAIL PROTECTED] writes:
> I don't understand what I don't understand in the following:
I haven't tried to understand what your code is doing - but the
NameError arises because you try to use Loc before its definition. Put
the definition first and the error should go away.
--
http://mail.pyth
On Dec 12, 2007, at 11:26 AM, [EMAIL PROTECTED] wrote:
> I don't understand what I don't understand in the following:
You also don't understand how to ask for help properly. Your example
is too large, for one. You want a "minimal working example" (http://
ironfroggy-code.blogspot.com/2007/02/m
I don't understand what I don't understand in the following:
--
# reader.py - testing char-by-char marching methods
f = open('sample_decaf.d', 'r')
text = f.readlines()
f.close()
# this is C-style, 15 lines, in Python:
end_line = len(text)
line_ptr = 0
whi
11 matches
Mail list logo