["python","python-venv"]
How to create a venv with a different Python version

I have different venvs in my machine in which I have Python 3.10. Now for a specific project, I realised that Python 3.10 is not suitable as some libraries are still not compatible. Therefore, when creating a new venv for a new project, I would like to downgrade Python, say to 3.8, only for this specific venv. How can I do that? What should I type onto the terminal to do this? PS: I use Visual Studio Code and its terminal to create venv.
You can have multiple Python interpreter versions installed at the same time and you can create virtual environments with the needed version. Make sure you have installed the Python version you need and then specify its location when you create the virtual environment: virtualenv -p <path-to-new-python-installation> <new-venv-name> Example: virtualenv -p C:\Users\ssharma\AppData\Local\Programs\Python\Python38\python.exe venv38 This will create a virtual environment called venv38 with Python 3.8.