Python Installation & Python Virtual Machine (PVM)
How to Install Python (Windows)
Steps to Install Python
-
Download Installer
Official Python website par jaakar latest Python 3 version download karein. -
Run Installer
Downloaded .exe file par double-click karein. -
Important Options Select Karein
- Add Python to PATH → Command line se Python run karne ke liye zaroori
- Install for all users (optional but recommended)
-
Install Python
“Install Now” button par click karein. -
Verify Installation
Command Prompt (cmd) open karke likhein:python --version
Agar Python version show ho jaye, to installation successful hai.
Python Virtual Machine (PVM)
Python Virtual Machine (PVM) ek runtime engine hai jo Python programs ko execute karta hai.
Ye Python bytecode aur computer hardware ke beech ek bridge ka kaam karta hai, isi wajah se Python ek cross-platform language hai.
How PVM Works
1. Compilation to Bytecode
.pysource code pehle bytecode me convert hota hai- Bytecode platform-independent hota hai
-
Bytecode memory ya
__pycache__ folder me
.pycfile ke roop me hota hai
2. Execution by PVM
- PVM bytecode ko line-by-line read karta hai
- Use machine code me translate karke execute karta hai
- Isi wajah se Python ko interpreted language kaha jata hai
Important Note
- Python source code directly machine code me convert nahi hota
- Pehle bytecode banta hai, phir PVM usse execute karta hai
- PVM Python interpreter ka core part hota hai