Asrarahmed Kadri wrote: > > Hi Folks, > > Just a bit curious about how python runs the program? > > I do know that it does not compile the code; its an interpreted language. > > Do we have something like Python virtual machine ?? > > Please hlep me to understand these things.
Yes, Python has a bytecode compiler and a virtual machine (bytecode interpreter). The compiler is invoked automatically when needed so it is not really apparent to a casual user. The dis module in the standard library lets you see the bytecode representation of a function or other code. The docs for this module include a listing of all the bytecode instructions. If you want to dig into the details you have to look at the C source code for Python. This page gives a high-level guide: http://effbot.org/pyfaq/where-do-i-start-if-i-want-to-learn-about-the-cpython-implementation.htm Kent _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor