CPython Execution
How does CPython run code?
Answer
First, CPython compiles the
.pyfile into bytecode (.pyc). This bytecode is not machine code; it is an intermediate, platform-independent format.Then, the bytecode is sent to the Python Virtual Machine (PVM), which interprets and executes the instructions one by one.