DEV Community

loading...
Cover image for Install coding tools for Python development

Install coding tools for Python development

joelbuenrostro profile image Joel Buenrostro ・3 min read

In this post, you'll be introduced to Visual Studio Code, Python, and Jupyter Notebooks. You'll learn how to install all the software and packages you'll need to begin writing code.

Prerequisites

  • A Windows, Mac, or Linux computer
  • Knowledge of how to download programs from the Internet

What is code?

Lines of code are instructions that humans give to computers to make them do things. While you may hear about how smart and amazing computers are, on their own, they are only good at one thing: following explicit instructions.

What is Visual Studio Code?

Visual Studio Code (often referred to as VS Code) is a free, open-source, extensible, code editor. We can break this description down a little further to get a better understanding:

  • Code editor: A code editor is made specifically for writing, running, and debugging code. Code editors can be compared to an application like Microsoft Word, but having additional functionality such as autocomplete of code functions and the ability to execute, or run, code.

  • Open-source: Open Source Software (OSS) has its code available for anyone to explore, modify, and enhance. The main takeaway from this is that anyone, even you, can build a new feature in software such as Visual Studio Code and contribute it back to the source code for others to use. You can find the open-source Visual Studio project on GitHub

  • Extensible: Extensible means that something can be extended and expanded. In the context of Visual Studio Code, being extensible means that you can download, or even create, extensions to make Visual Studio Code exactly right for your work style. Think mods in a game or customizations. If the color scheme is hurting your eyes or an obscure programming language isn't supported, you can customize Visual Studio Code to add new colors or support for the language. You can find the Visual Studio Code extensions on the marketplace or discover how to build your extension in the Visual Studio Code documentation.

Install Python extension

Click on the extension tab in Visual Studio Code to access all the Python open-source tools that'll be helpful for this learning path. The extension tab looks like three blocks in the shape of an "L" with another block floating to the right.
If you want to, you can explore the extensions marketplace and install any extensions you'd like to have, but for this tutorial, we'll install the Python extension. When you're in the extension marketplace, go to the search bar and type "Python". Look for the extension named solely Python and published by Microsoft - it should be the first result. Click on the extension and then click "install".

Python Extension

Install IntelliCode extension

While you're in the extensions tab, go back to the search bar and type in "intellicode". Select the specified box. It should be the first result. Select Install. IntelliCode will recommend code when you're writing programs, which is a great tool for beginners who might not know the exact syntax.

Intellicode Extension

Information about Jupyter Notebooks

Visual Studio Code Jupyter Notebooks has good documentation about how to use the environment. In Jupyter notebooks, you write code in cells. Click on the plus button to the left of a cell to create a new cell below the current cell. Click on the garbage can to the right to delete the selected cell and use the arrow buttons to move the cell up or down in relation to the cells around it.
Use the green play button in each cell to run that cell. After you run a cell, a number will appear, surrounded by square brackets. This number is to help you keep track of which cells you run. This is important because, as you'll remember, you can re-run cells within a Jupyter Notebook, which might change variables or program state.
If you look at the top of the file, you will see that you can run all cells above or below the current cell by using the play button. Finally, you can click the red pause button to force stop the program at any time.

The Jupyter notebooks have been widely adopted by the data science community of practitioners to hypothesize and visualize data in a format that enables rapid prototyping of their applications.

As always, thanks for reading and happy coding!!!

Discussion (4)

pic
Editor guide
Collapse
alexgeorgiev17 profile image
Alex Georgiev • Edited

Great post! Thanks for sharing it! What about using PyCharm, do you think it's better to use it instead of VS code.

Collapse
joelbuenrostro profile image
Joel Buenrostro Author

Hi Alex, thanks for commenting! I use both, VSCode is becoming a favorite of many programmers, it is very easy to use and the support has been quite good. I think PyCharm is also very good as it is only intended for Python, the combination of PyCharm and Kite is very powerful, PyCharm is also good at developing large-scale projects and very popular in teams with Python as the main language. My recommendation would be to learn both tools, for daily use and personal projects I'm using VSCode, and for projects in a business environment, I would use PyCharm, also for prototyping code I'm using Jupyter lab.

Collapse
alexgeorgiev17 profile image
Alex Georgiev

Thanks, for the feedback, Joel! I will make sure to try out PyCharm as well

Thread Thread
joelbuenrostro profile image
Joel Buenrostro Author

Claudia Regio recently published the upcoming characteristics to integrate in VSCode, I share the link, maybe you can find it interesting.

youtube.com/watch?v=g5EykzAsCC0

regards.