1) Python Introduction
1) Python Introduction
what is programming
what is diff betn compiler and interpreter
programming languages:
it is used to communication betn human and computer
programming language:
each programming lang has its own syntax:
compiler:
-Takes entire program and translate as a whole into machine code
c-language
- displays all errors and warnings at a time and without fixing all errors, program cannot be
converted into machine code
--Generate object code so need memory
--debugging is slow and time consuming
--execution fast
interpreter:-
Takes one statement and translate it line by line execution
python language
--shows one error at a time and you have to fix the error to interpret next statement
---no object code is generated. memory efficient
--Execution slow
--debugging is fast
What is python?
python is a high level programming lang
--python is a simple, high level, interpreted, dynamically typed programming language
========================================================
which language is simple
==========================================================
in java:
in C:
#include <stdio.h>
int main() {
printf("Hello\n");
return 0;
}
in python:
print("Hello")
=================================================================
features of python
=======================================================================
simple and easy to learn
freeware and open source
high level programming lang
platform independent--we can run python program on any platform i.e windows,linux
portability--we can run python program on any platform i.e windows,linux
Dynamically typed
Both procedure oriented and object oriented
interpreted
extensive library
limitations of python
1. slow
2.not used for mobile application
======================================================================
flavours of python
===================================================================
1. cpython
2.java-python-jython/jpython
3. iron python
C#.net
4.pypy
for performance with jit compliler
5.ruby python
for ruby platforms
6.anaconda:
=========================================================================
IDE- Integrated Development Environment
=========================================================================
installing notebook-- pip install notebook in cmd
in anaconda launch jupyter notebook
===========================================================================
==
what is program
int a=10
a=10
================================================
limitations:
1.slow
2. cant use for mobile applications