Python for a PHP user, how do i...?

Rainer Deyke root at
Wed May 16 01:20:59 CEST 2001

"rw2" <richw at> wrote in message
news:20010515.162432.2118421993.2310 at
> Stop the presses.  I just found 'exec'.  That's the general purpose
> function I was looking for.  Don't do the compile nonesense I previously
> recommended.  exec does it for you in one cleaner step.

Except that 'exec' isn't a function.  You can't do this:

eval('exec "print \'spam\'"')

or this:

f = exec

Rainer Deyke (root at
Shareware computer games           - 
"In ihren Reihen zu stehen heisst unter Feinden zu kaempfen" - Abigor

More information about the Python-list mailing list