Python Programming

Getting Started
Basic Programming Concepts
Writing First Program

Python - Getting Started

Amit Mathur · 3 mins read ·
python beginners

Introduction

Python is a widely-used programming language nowadays for a wide magnitude of tasks like general programming, web development, data analysis and machine learning.

Thanks to a variety of features, most developers are now moving to python language for their development work. Also, most IT professionals are intended to Learn Python Language.

Python was founded by Guido van Rossum during 1985-1990.

Python is a high-level language based on Object-Oriented programming model. This means that everything that is coded is modeled into classes and objects.

Features of Python:

  • Python is an interpreted language
Unlike other programming languages, like Java, Python does not have a separate compilation step.

The implementation of Python follows the interpretation model. The code is processed at run-time by an interpreter. There is no need to compile the code.

Due to this reason, Python is very easy to debug things on production as compared to languages like Java.

I have already shared a post to explain more on this point: Java VS Python

  • Python is very interactive
Python syntax resembles much like normal English language hence easy to interact with.

Four EASYs of Python

Because of its easy syntax, and an ability to write code in fewer lines of code, the below activities becomes very easy: Easy to write, Easy to learn, easy to read, easy to understand, Easy to maintain

  • Semicolons are not used
Python code does not have a semicolon way of ending a line as it is used in some other languages like Java, JavaScript, C++ etc. The end of the line is the end of the command.

  • Python follows indentation
Python uses indentation to define the scope of the line of code. For example, the code is written in any loop (for, if) has to follow indentation.

for a in list(1, 3, 5):
    print(a)

if a == b:
    print("Same")
  • Python is a dynamically typed language
There is no need to declare variables or their types in advance. We can use it whenever we want. The value of the variable will decide its type.

Although the newer versions of python allow you to explicitly add types of Python but it’s not well used in the community.

def pythonprogrammingorg(name: str) -> str:
    return f"{name} writes on pythonprogramming.org"

pythonprogrammingorg("Amit")

Out[2]: 'Amit writes on pythonprogramming.org'
Because of all the above-mentioned features, it’s very interesting and easy to Learn Python Language. Many programmers believe that Python should be the first programming language that a Programmer should learn.

What is the Python Software Foundation?

PSF is Python Software Foundation whose task is to promote, protect and advance Python language and work on the updates periodically.

It is the parent body that manages and produces core Python distribution. Since Python and its distribution is open source, other partners also have the freedom to work on their own Python distribution many of which are available in the market.

The Python distribution maintained by PSF is based on C language hence also known as CPython. There is a Python version based on Java which is known as JPython.

The core Python distribution version currently in use is Python 3.0 and above. Earlier version Python 2.0 is compatible is Python 3.0.

Installation

Unix systems comes with pre-installed Python. So you should be able to run this stuff out of the box.

Just open the shell and type,

python -v
to know the Python version.

For Windows you can download the latest version from here install it on your machine.



About Author

Amit Mathur
Amit Mathur is a Software Professional having 12 years of experience. He is a professional blogger and write blogs on Python Tutorials for beginners.

Please share your Feedback:

Did you enjoy reading or think it can be improved? Don’t forget to leave your thoughts in the comments section below! If you liked this article, please share it with your friends, and read a few more!