Python Language Fundamentals
Topics Covered:
Introduction
Application areas of Python
Features of Python
Limitations of Python
Flavours of Python
Python Versions
Identifiers
Reserved Words
Datatypes
Typecasting
NOTE: If you really strong in the basics, then remaining things will become so easy
L1: What is Pyhton?
It is a Programming Language.
- We can develop applications by using this programming language.
We can say that, Python is a High-Level Programming Language. Immediately you may get doubt that,
What is the meaning of High-Level Programming Language.
- High-Level means Programmer friendly Programming Language. This means we are not
required to worry about Low-level things [i.e., Memory management, security, d
estroying the objects and so on.]
- By simply seeing the code programmer can understand the program. He can write th
e code vey easily.
- High level languages are Programmer friendly languages but not machine friendly
languages.
Let's take the following example,
localhost:8888/notebooks/Desktop/PythonCourse/Python Language Fundamentals.ipynb 1/81
, Python Language Fundamentals
Let s take the following example,
a = 10
b = 20
c = 30 if a>b else 40
print(c)
Do you Know, if we can take this code, are in a position to understand this code?
You are not required to have any programming knowledge.
By observing the code you can say that, the value stored in C is 40
If you have the kid, can you please show this 4 lines code and ask what is the ouput, your kid is able to answer
without having any hesitation. This type of thing is called as High level programming.
Examples of High Level Programming Languages :
C
C++
Java
C#
Python
You may get doubt that, you are writing just 4 lines code, is it really a Python code? Is it going to Work?
Let's execute and see what happens,
In [1]:
a = 10
b = 20
c = 30 if a>b else 40
print(c)
40
It is perfectly Python code. This is called High level programming.
Python is a General Purpose High Level Programming Language.
Here, General Purpose means Python is not specific to a particular area, happily we can use Python for any
type of application areas. For example,
Desktop Applications
Web Applications
localhost:8888/notebooks/Desktop/PythonCourse/Python Language Fundamentals.ipynb 2/81
,14/04/2020 Python Language Fundamentals
Data Science Applications
Machine learning applications and so on.
Everywhere you can use Python.
L2: Who Developed Pyhton?
Who provides food for most of the programmers across the worldwide.
Guido Van Rossum developed Python language while working in National Research Institute (NRI) in
Netherland.
When he developed this Language?
Most of the people may think that so far we are heared about Java, C and C++ and we are recently knowing
about python (especially in our INDIA) and they may assume that Python is a new programming language and
Java is a old programming language.
Java came in 1995 and officially released in 1996.
Python came in 1989, this means that Python is Older programming language tha Java. Even it is
developed in 1989, but it is not released to the public immediately.
In 1991, Pyhton made available to the public. Officially Python rleased into the market on 21-02-1991 (i.e.,
First version).
Then, Immediately you may have a doubt that, Why Python suddenly (in 2019) became Popular?
Generally Market rquirements are keep on changing from time to time.
Current market situation is, every one talks about
- I need Simple Language (i.e., Easy to understandable)
- I have to write very less (or) concise code to fulfill my requirement.
- In these days, everyone talks about AI, Machine Learning, Deep Learning, Neural
networks, Data Science, IOT.For these trending requirements, best suitable program
ming language is Python.
That's why in these days, Python becomes more popular programming language.
For example, Suppose you have a diamond. When there is a value for that diamond is, if the market
requirement is good for that, then automatically this diamond value grows.
Date: 10-04-2020 - Day 2
L3. Easyness of Python compared to other programming languages
If you want to learn Python programming, what is the prerequisite knowledge required?
The answer for the above Question is:
localhost:8888/notebooks/Desktop/PythonCourse/Python Language Fundamentals.ipynb 3/81
, 14/04/2020 Python Language Fundamentals
Nothing is required, If you are in a position to read English statements, that is enough to learn Pyhton
programming.
Eg:
If you are learning any programming language, the first application which we discuss is Hello World
application.
In 'C'
1) #include <stdio.h>
2) void main()
3) {
4) printf("Hello World");
5) }
In 'Java'
1) public class HelloWorld
2) {
3) public static void main(String[] args)
4) {
5) System.out.println("Hello world");
6) }
7) }
In 'Python
In [1]:
print("Hello World");
Hello World
In [3]:
print("Hello World") # ';' is also optional
Hello World
Just to print 'Hello World',
C language takes 5 lines of code
Java takes 7 lines of code
But, Python takes only one line of code.
localhost:8888/notebooks/Desktop/PythonCourse/Python Language Fundamentals.ipynb 4/81