Class-1-Introduction - Python
Class-1-Introduction - Python
Class-1-Introduction - Python
Topics to be covered
• Why python is popular
• Brief history of python
• Features of Python
• Comparison of python with C and Java
• Execution of a python program
• Installing python for windows
Why python is popular
Procedure Oriented Programming languages
Collection of functions
Ex: C,FORTRON,PASCAL
written using functions, Hence in C all
statements must be written in main function
Object Oriented Programming languages
to solve real life problems
Ex. JAVA,.NET uses concepts of classes and objects
Contd.
• Java is the most popular language. Draw back
is everything is represented in terms of classes
and objects
Exercise: Write a java program to add two
numbers
Write a C program to add two number
Observation: Length of C program is less but real
life problems can not be solved
• A language which includes C and Java style
coding is required.
• Python is the language which contains the
features of C and Java
#python program to add two numbers
a=b=10
print(“sum=“,a+b)
Brief History
• Guido Van Rossum developed a language to fill
the gap between C and Shell in the year 1991
at the centre for mathematics and computer
science managed by dutuch Government. This
has lead to the development of python.
• Python name is selected TV show Monty
pythons Flying circus.
• First version released on feb 20 1991
• Logo of python inter winded snakes
Features of Python
• Simple
• Easy to learn
• Open source
• High Level language
• Dynamically typed
• platform independent
• portable
• Procedure and object oriented
Contd.
C PYTHON
C is procedure oriented language Python is object-oriented language
C program executes much faster Python program executes much slower
It is compulsory to declare varibles,arrays
It is not compulsory
etc
Python language type discipline is
C language type discipline is static and
dynamic and strong
weak
Compile
Run Using Python
Using
Virtual Machine
Python
Compiler
• https://anaconda.org/anaconda/python
• Python anaconda cloud
• Download