Introduction to Python

Introduction to Python

Python is a widely used general-purpose, high level programming language. It was created by Guido van Rossum in 1991 and further developed by the Python Software Foundation. It was designed with an emphasis on code readability, and its syntax allows programmers to express their concepts in fewer lines of code.


What Python can do?
  • Python can be used on a server to create web applications.
  • Python can be used alongside software to create workflows.
  • Python can connect to database systems. It can also read and modify files.
  • Python can be used to handle big data and perform complex mathematics.
  • Python can be used for rapid prototyping, or for production-ready software development.

Why Python?

  • Python works on different platforms (Windows, Mac, Linux, Raspberry Pi, etc.)
  • Python has a simple syntax similar to the English language.
  • Python has syntax that allows developers to write programs with fewer lines than some other programming languages.
  • Python runs on an interpreter system, meaning that code can be executed as soon as it is written. This means that prototyping can be very quick.
  • Python can be treated in a procedural way, an object-oriented way or a functional way.

Prerequisites:

Knowledge of any programming language can be a plus.


Python compared to other Programming Language:


Python

Java

Dynamically Typed 

  • No need to declare anything. An assignment statement binds a name to an object, and the object can be of any type.
  • No type casting is  required when using container objects

Statically Typed

  • All variable names (along with their types) must be explicitly declared. Attempting to assign an object of the wrong type to a variable name triggers a type exception.
  • Type casting is required when using container objects.
Concise Express much in limited wordsVerbose Contains more words
CompactLess Compact
Uses Indentation for structuring codeUses braces for structuring code


The classical Hello World program illustrating the relative verbosity of a Java Program and Python Program


 Python Program:                                 Java Program:

     print("Hello, world!")                              public class HelloWorld {

                                                                        public static void main (String[] args) {

                                                                        System.out.println("Hello, world!");

                                                                        }

                                                                   }


Current Applications of Python:

  1. A number of Linux distributions use installers written in Python example in Ubuntu we have the Ubiquity
  2. Python has seen extensive use in the information security industry, including in exploit development.
  3. Raspberry Pi– single board computer uses Python as its principal user-programming language.
  4. Python is now being used Game Development areas also.

Pros:

  1. Ease of use
  2. Multi-paradigm Approach

Cons:

  1. Slow speed of execution compared to C,C++
  2. Absence from mobile computing and browsers
  3. For the C,C++ programmers switching to python can be irritating as the language requires proper indentation of code. Certain variable names commonly used like sum are functions in python. So C, C++ programmers have to look out for these.

Applications : 

  1. GUI based desktop applications
  2. Graphic design, image processing applications, Games, and Scientific/ computational Applications
  3. Web frameworks and applications 
  4.  Enterprise and Business applications 
  5.  Operating Systems 
  6. Education
  7. Database Access
  8. Language Development 
  9.  Prototyping 
  10. Software Development

Organizations using Python : 

  1. Google(Components of Google spider and Search Engine) 
  2. Yahoo(Maps) 
  3. YouTube 
  4. Mozilla 
  5. Dropbox 
  6. Microsoft 
  7. Cisco 
  8. Spotify 


Download and Install Python 3 Latest Version In Windows



How to install Python on Windows?

Since windows don’t come with Python preinstalled, it needs to be installed explicitly. Here we will define step by step tutorial on How to install Python on Windows. Follow the steps below :


Step 1: First and foremost step is to open a browser and type

                    https://www.python.org/downloads/windows/


Step 2: Underneath the Python Releases for Windows find the Latest Python 3 Release – Python 3.10.5 (the latest stable release as of now is Python 3.10.5).




Step 3: On this page move to Files and click on Windows x86-64 executable installer for 64-bit or Windows x86 executable installer for 32-bit. 




Here we are providing the installation process of Python 3.10.4 on Windows

  • Run the Python Installer for how to install python on windows downloads folder 
  • Make sure to mark Add Python 3.10 to PATH otherwise you will have to do it explicitly. It will start installing python on windows.



After installation is complete click on Close. Bingo..!! Python is installed. Now go to windows and type IDLE.




  • This is Python Interpreter also called Python Shell. I printed Hello learners, python is working smoothly.
  • The three greater than >>> sign is called Python command prompt, where we write our program and with a single enter key, it will give result so instantly. 

Follow for more contents about Python
Stay Tuned...! 

Comments