statements and expressions

Alves, Carlos Alberto - Coelce calves at coelce.com.br
Wed Jan 9 16:32:25 EST 2002


Why this two codes doesn't work?!
1º case:
	exec("print 'Carlos' ")
2º case:
	x = exec("something")
In former case, is it beacouse exec(..) requires an expression as argument
and print "...." is a statement? And in the latter, beacouse statements
doesn't support assignments?!

Thanks in advance,



Carlos Alberto
COELCE/DPRON-Departamento de Projetos e Obras Norte
Fone: 677- 2228
e-mail: calves at coelce.com.br
\|||/
(o o)
--ooo0-(_)-0ooo--


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20020109/cfa1bd1c/attachment.html>


More information about the Python-list mailing list