How to create a Python Environment in Visual Code?
Step-1:
Download the Python latest version from chrome browser.
Link: https://www.python.org/downloads/
Step-2:
Download anaconda from Chrome Browser.
Link: https://www.anaconda.com/download
After anaconda Downloaded follow these:
- Open the file
- click on next then “I Agree” and Choose option as “Just Me”
- Choose your specific location to save the application.
- Check box on: Add Anacoda3 to my PATH
- Then Install
- Click Next & finish button.
Step-3:
- Create a folder for the Python course only(name as Python)
- Open visual studio and click on file option (left top corner)
- select Open folder and open the created folder (Python)
Step-4:
- Open Terminal & select Command Prompt.
- write this line:
conda create -p venv python==3.12
(Note: if it not installed try, conda create -p venv python==3.14)
- Type y: When you see like this(Proceed ([y]/n)?
- You can see, required libraries are downloading.
(Note: It takes time to create Environment)
- On left side You can observe: “venv” environment is created and it contains required files.
Step-5:
- Create a python file using extension “.py” and check whether Python is downloaded or not.
- Write a simple program: print(3+2) and type “ctrl button + alt button + letter n”, code will run you can see the output as 5.
(Note: python is successfully downloaded here)
- create a new folder for the python basics, as I shown in the video.
- Create a file in that folder using “.ipynb” extension with name “first.ipynb”
Step-6:
- Try to run a code in the box, by typing “shift+enter”
- You can see an error(don’t worry that is common)
- In Terminal write like this:, pip install ipykernel
- Again you can observe files are downloading and these are kernel files.
- Now, run the code you can see the output here.
Miku Doubt ravachu, why bro this environment?
- Nenu kuda andhari lane vs code lo first python files laga cheppavachu but ela jupyter notebook miku alavatu chaste, miku tarwta help avuthadhi ani.
- miru videos chusi yadhi ithe practice chestaro mottam oke file lo untadhi, miku confusion undadhu ani ela chayamani cheppa.
- Still if you find any doubts, let me know. DM chayyandi!!
All The Best..!!
DAY - 01 (Introduction of Python)
Why Python? (3–12 sec)
"Python anedhi world's most versatile programming language."
"Data Science lo huge datasets ni analyse cheyyadaniki...
Machine Learning lo models train cheyyadaniki...
Web Development lo backend build cheyyadaniki...
Automation nunchi AI varaku... almost anni places lo Python use chestaru."
DAY - 02 (Variables, Keywords & Data Types)
1. What is a Variable?
A variable is a name used to store a value in a program.
Think of a variable like a labeled box 📦.
- Box name → Variable
- Thing inside the box → Value
For example:
name="Bharath"
age=21
Here:
name is a variable
"Bharath" is the value stored in name