In 1981, Richard Pattis wrote a delightful little book titled "Karel
the Robot, a Gentle Introduction to the Art of Programming." Pattis's
"Karel the Robot" was named after the author Karel Capek, who
popularized the word "robot" in his play "Rossum's Universal Robots".
Pattis's approach was to int
I have the following two files:
#--testexec.py--
def exec_code(co):
try:
exec co
except:
print "error"
#-- test.py--
import thread
import testexec
import time
code = "def a():\n print 'a'\n\n" +\
"def c():\n a()\n\nc()"
code2 = "def a():\n print 'a'\n\n" +\