Install Python support in Visual Studio
Python support is presently available only on Visual Studio for Windows; on Mac and Linux, Python support is available through Visual Studio Code.
Download and run the latest Visual Studio installer for Windows (Python support is present in release 15.2 and later). If you have Visual Studio installed already, run the Visual Studio installer and go to step 2.
The installer presents you with a list of workloads, which are groups of related options for specific development areas. For Python, select the Python development workload and select Install:
To quickly test Python support, launch Visual Studio, press Alt+I to open the Python Interactive window, and enter
2+2. If you don't see the output of 4, recheck your steps.