Re: Is anyone using Python for embedded applications?

2006-12-13 Thread Hendrik van Rooyen
"Paul Boddie" <[EMAIL PROTECTED]> wrote: > Interesting! Any links, or is it related to the Telit hardware already > discussed? telit it was... - Hendrik -- http://mail.python.org/mailman/listinfo/python-list

Re: speed of python vs matlab.

2006-12-13 Thread Jonathan Curran
On Wednesday 13 December 2006 18:07, Chao wrote: > I've been trying to develop some numerical codes with python, however > got disappointed. > > A very simple test, > > a = 1.0 > > for i in range(1000): > for j in range(1000): >a = a+1 > > unfortunately, it took 4.5 seconds to fini

Re: job posting: Sr Systems Programmer needed

2006-12-13 Thread Terry Reedy
<[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > View the Job Descriptions: www.myspace.com/agcocorp I did and it has nothing to do with Python. So in the context of this newgroup, this announcement is spam. Please desist in the future. If everyone else with an unreleated programmer

Re: merits of Lisp vs Python

2006-12-13 Thread Paul Rubin
Ken Tilton <[EMAIL PROTECTED]> writes: > don't know. The point is, we need code (not just data) in defskill > (apologies for nasty formatting): Man that whole thing is messy. I can't for the life of me understand why it's so important to use a macro for that. Even in Lisp, I'd probably set up th

Re: job posting: nothing about Python there

2006-12-13 Thread Paul Rubin
Looks like a generic Windows weenie gig: Will serve as a programmer in the following program languages: RPGIII, RPGILE, Microsoft Access, SQL, Microsoft SQL Server, XML, Cold Fusion, and other web development tools. -- http://mail.python.org/mailman/listinfo/python-list

Re: merits of Lisp vs Python

2006-12-13 Thread Ken Tilton
Paul Rubin wrote: > Ken Tilton <[EMAIL PROTECTED]> writes: > >>don't know. The point is, we need code (not just data) in defskill >>(apologies for nasty formatting): > > > Man that whole thing is messy. I can't for the life of me understand > why it's so important to use a macro for that. Ev

Re: merits of Lisp vs Python

2006-12-13 Thread Paul Rubin
Ken Tilton <[EMAIL PROTECTED]> writes: > > Man that whole thing is messy. I can't for the life of me understand > > why it's so important to use a macro for that. Even in Lisp, I'd > > probably set up the reverse thingie as an auxiliary function. > > And when you got to skill 42 and you discover

Re: merits of Lisp vs Python

2006-12-13 Thread Ken Tilton
Ken Tilton wrote: > > > Paul Rubin wrote: > >> Ken Tilton <[EMAIL PROTECTED]> writes: >> >>> don't know. The point is, we need code (not just data) in defskill >>> (apologies for nasty formatting): >> >> >> >> Man that whole thing is messy. I do not see much difference, except that the charac

Re: merits of Lisp vs Python

2006-12-13 Thread Paul Rubin
Ken Tilton <[EMAIL PROTECTED]> writes: > >> Man that whole thing is messy. > > I do not see much difference, except that the character count is 25% > less in the macro version: The macro calls aren't so bad, but the macro definition is pretty horrendous. There's no need to invent and program all

Re: The Famous Error Message: "ImportError: No module named python_script"

2006-12-13 Thread Fredrik Lundh
rich murphy wrote: > Thank you both for responding. > > Yes of course the file has the ".py" extension and yes I went through > the tutorial. since everyone on this forum is importing modules successfully hundreds of times every day, that's not obvious at all. try running the interpreter as

Re: The Famous Error Message: "ImportError: No module named python_script"

2006-12-13 Thread rich murphy
Ben Finney wrote: > "rich murphy" <[EMAIL PROTECTED]> writes: > > > I am studying Python language. > > Welcome! Allow me to direct you to the Python tutorial: > > http://docs.python.org/tut/> > > Please take the time to work through all the exercises in that > document, understanding each one

Re: Conditional iteration

2006-12-13 Thread at
My comments below. Kind regards, @ Carl Banks wrote: > at wrote: >> Well, all I can say that for me as a user it would make sense... > > Which is, like, step one out of a hundred for getting a syntax change > into the language. > >> Curiosity: in what sense is it redundant? > > It creates sy

Re: Conditional iteration

2006-12-13 Thread at
Thanx Paul! Do you know if this generates a new list internally (memory consumption?) @ Paul Rubin wrote: > at <[EMAIL PROTECTED]> writes: >> You proposal, seems nice to me but it doesn't work with Python 2.4.3, >> should it work with 2.5? >> >> Again I am just wondering if the approach for >

Pythonic style involves lots of lightweight classes (for me)

2006-12-13 Thread metaperl
I find it arduous to type dictionary['key'] and also feel that any data I create for a program deserves to have its operations tied to it. As a result, I often create lots of lightweight classes. Here's a small example: vlc = '/Applications/VLC.app/Contents/MacOS/VLC' class song(object): def

Re: Conditional iteration

2006-12-13 Thread at
Hi Greg, Well point is that the condition is the only thing happening and does not really apply to the indented code section, but basically to the list used in the indented code section. When I read this code back its like, 'oh we use this list' and by the if some_condition the next thing I think

Re: merits of Lisp vs Python

2006-12-13 Thread Ken Tilton
Paul Rubin wrote: > Ken Tilton <[EMAIL PROTECTED]> writes: > >>>Man that whole thing is messy. I can't for the life of me understand >>>why it's so important to use a macro for that. Even in Lisp, I'd >>>probably set up the reverse thingie as an auxiliary function. >> >>And when you got to ski

Re: The Famous Error Message: "ImportError: No module named python_script"

2006-12-13 Thread Eric Pederson
rich murphy wrote: >So, I assumed "the current directory" is C:\Python25 which did not >work. Then I placed the fibo.py file in C: director. That did not work >either. What directory does it mean then? > OK, forgive me for using 2.4... Can you import "sys"? Assuming you've got python_script.py

Re: merits of Lisp vs Python

2006-12-13 Thread Paul Rubin
Ken Tilton <[EMAIL PROTECTED]> writes: > btw, you called the defskill messy (repeated below) "messy". The only > text not specific to absolute value is D-E-F-S-K-I-L-L. No, the messiness was not in the macro instantation (defskill blah...), but in the defmacro that tells the compiler how to expand

Re: Conditional iteration

2006-12-13 Thread Paul Rubin
at <[EMAIL PROTECTED]> writes: > > for x in (x for x in [-2, -1, 0, 1, 2, 3, 4] if x > 0): > >... more code ... > Do you know if this generates a new list internally (memory consumption?) It does not. That parenthesized expression is a called generator expression. It compiles to a sma

Re: merits of Lisp vs Python

2006-12-13 Thread Ken Tilton
Ken Tilton wrote: > > > Ken Tilton wrote: > >> >> >> Paul Rubin wrote: >> >>> Ken Tilton <[EMAIL PROTECTED]> writes: >>> don't know. The point is, we need code (not just data) in defskill (apologies for nasty formatting): >>> >>> >>> >>> >>> Man that whole thing is messy. > > > I d

<    1   2   3