PYTHON 101: INTRODUCTION TO MODERN PYTHON
Published: 2022-02-13 15:40:45

**Python 101 : INTRODUCTION TO MORDEN PYTHON**
 
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jjp0hpijnv7aif1njduy.png)
The Python language type is a high-level cross-platform free and open-source, dynamically typed one that is among the most popular general-purpose programming languages. It is among the world’s fastest-growing programming languages and is used by software engineers, mathematicians, data analyst, scientists, network engineers, students and accountants.
Python is a very easy programming language to pick up, is beginner-friendly which prioritizes readability. Its syntax has similarities with the English language, so if you have chosen Python to learn as your first programming language, you are in very good hands.
Python was created in 1989 by Guido van Rossum and released later in 1991. Guido’s main priority in creating Python was to make programming easier. As to how the name “Python” came about, Guido took inspiration from a BBC comedy book titled “Monty Python Flying Circus” and decided he needed a short name, slightly mysterious and unique. 

**Getting started with Python**
Python, as mentioned earlier is a cross-platformed programming language, meaning it can be ran on Windows, Linux or MacOS. 
Installation
Python installation is a piece of cake, and recently a lot of LINUX and UNIX distributions have Python. Even some Windows machines have Python already installed on it. Check out https://www.python.org/ to know how to install python for the first time.
 

– Check if you already have python installed via command line.
-	On your device, click the search icon and type cmd to search for the Command Prompt.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jq4o2xtgbmx98fcyax8v.png)
 
-	Check if you already have python installed. 
On your command prompt, type in the command python –version, python -V or py –version to see if you already have python installed and placed in your environment variables. These commands also tell you what version is installed in your device. 
As you can see on the image below, I have version 3.9.7 installed on Windows.
You can also find the location where it was installed using the where.eve python command.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rs4ulndf0bx5w71g84aa.png)
 

If python hasn’t yet been installed on your desktop, then visit https://www.python.org/downloads/windows/ select the version suitable for your device (whether 64-bit or 32-bit)
 
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/99w7blowuxjmbrp92szr.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tad6tskz4msghts0wkhf.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/68do2rlkylyw9g1yq1tq.png)
 
 
Installation was successful. To verify if python was correctly added to your path, check the python version on command prompt as shown above.
OR to add python to your environment variables, click on the search icon and type in “python” and open its location 
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a8bwn7cvx4s4y3d2xeci.png)

Copy the file location highlighted in blue as in the image below;
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/afp122ad8t04td85nma7.png)
 
Click on the search icon again and type in “Edit the system environment variables” and enter.
A little dialog box will pop up and then click on “Environment Variables”
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0for9eqsbkmtpt81fup9.png)
 
In the environment variables, double-click on “Path” to add the python path and click on “OK”
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2hp1l8ivumuys6ukgco5.png)
 
Now to check if python is properly installed in your machine once more, open command prompt and type in python –version command.

**Python IDE:**

Haven installed python and added it to your environment, open the search bar and type in “Python IDLE” and open.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3l3tm0gljuumuiqfpei6.png)
 When the IDLE is opened, it looks like this; 
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yoq1m8plxbaeilt8925g.png)
Navigate to File>New file to open a new python file and save this file in any desired location or press CRTL+N keys to open a new python file.
Save the file as “hello_world.py” or in our case “hello_pythonista.py”

Typing in your first python program as it is below; ![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/drg64pbni6by1nzrfpvl.png)

Save this program and run this program as in the image below; 
Execute the program  
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r36jxuf3twc8cf1swwqw.png)
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iy23toc408c2af7v6602.png)

Alternatively to run your code from the command prompt:

- open the command prompt

- Navigate to the folder containing your '.py' file

- Run the command _python fileName.py_ then hit "Enter".

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vkuz06cj5xl5416n8wmo.png)

HURRAY! You have executed your very first program as a python programmer.
Welcome to the world of Python. Pretty easy and interesting, isn’t it?

**_Pep talk_**

As you have seen, writing programs is very easy. One of my teachers made the definition of programming very easy as “Programming is simply telling your computer what to do”. 
CONSISTENCY is the key as a programmer and to be consistent, you must be disciplined to know exactly what you want.  
To learn more about python, you can visit the following;
-	https://www.udemy.com/course/python-programming-tutorial-a-z/
-	https://www.freecodecamp.org/news/the-best-way-to-learn-python-python-programming-tutorial-for-beginners/
-	https://www.simplilearn.com/tutorials/python-tutorial
I hope this article has been of help to you. 
HAPPY CODING, PYTHONISTA!!!!