SlideShare a Scribd company logo
1 of 15
Python Training in
Chandigarh(Mohali)
1
About us
We Are The Best Web Designing Institutes In Chandigarh Providing
World Class Web Designing Classes Mohali Especially To Learners,
Housewives & Other Who Are Looking For Web Designing Classes. We
Have Taught More Than 6000+ Students In The Past 10 Years. After
Completing Web Designing Institute In Mohali ,Many Facilities Are
Provided . You Will Be Able To Build Faster & 100% Responsive Website
That Deliver Better Results. You Will Get Assured Job After Completing
Your Course. Web Designing Training In Mohali.
2
3
Filename, preferred extension is py
User Program
Interacting with Python Programs
• Python program communicates its results to
user using print
• Most useful programs require information
from users
– Name and age for a travel reservation system
• Python 3 uses input to read user input as a
string (str)
4
input
• Take as argument a string to print as a prompt
• Returns the user typed value as a string
– details of how to process user string later
5
IN[1]:
IN[2]:
IN[3]:
( )
Elements of Python
• A Python program is a sequence of definitions
and commands (statements)
• Commands manipulate objects
• Each object is associated with a Type
• Type:
– A set of values
– A set of operations on these values
• Expressions: An operation (combination of
objects and operators)
6
Types in Python
• int
– Bounded integers, e.g. 732 or -5
• float
– Real numbers, e.g. 3.14 or 2.0
• long
– Long integers with unlimited precision
• str
– Strings, e.g. ‘hello’ or ‘C’
7
Types in Python
• Scalar
– Indivisible objects that do not have internal
structure
– int (signed integers), float (floating point), bool
(Boolean), NoneType
• NoneType is a special type with a single value
• The value is called None
• Non-Scalar
– Objects having internal structure
– str (strings)
8
Type Conversion Examples
9
Note that float to int conversion
is truncation, not rounding off
Type Conversion and Input
10
Operators
• Arithmetic
• Comparison
• Assignment
• Logical
• Bitwise
• Membership
• Identity
Jan-23 Programming
11
+ - * // / % **
== != > < >= <=
= += -= *= //= /= %= **=
and or not
in not in
is is not
& | ^ ~ >> <<
Variables
• A name associated with an
object
• Assignment used for binding
m = 64;
c = ‘Acads’;
f = 3.1416;
• Variables can change their
bindings
f = 2.7183;
12
64
Acads
3.1416
2.7183
m
c
f
Multiple Assignments
• Python allows multiple assignments
x, y = 10, 20
• Evaluation of multiple assignment statement:
– All the expressions on the RHS of the = are first
evaluated before any binding happens.
– Values of the expressions are bound to the
corresponding variable on the LHS.
x, y = 10, 20
x, y = y+1, x+1
13
Binds x to 10 and y to 20
x is bound to 21
and y to 11 at the
end of the program
Binary Operations
14
Op Meaning Example Remarks
+ Addition 9+2 is 11
9.1+2.0 is 11.1
- Subtraction 9-2 is 7
9.1-2.0 is 7.1
* Multiplication 9*2 is 18
9.1*2.0 is 18.2
/ Division 9/2 is 4.25 In Python3
9.1/2.0 is 4.55 Real div.
// Integer Division 9//2 is 4
% Remainder 9%2 is 1
Web Designing Training in
Chandigarh(Mohali)
Address: Plot No C-133, near Gold Gym, Phase-8, Sahibzada Ajit
Singh Nagar, 160055
Phone: +91 93562-55522
Website: http://excellenceacademy.co.in/
15

More Related Content

Similar to Python Training in Chandigarh(Mohali)

Cs1123 11 pointers
Cs1123 11 pointersCs1123 11 pointers
Cs1123 11 pointers
TAlha MAlik
 

Similar to Python Training in Chandigarh(Mohali) (20)

Welcome to python workshop
Welcome to python workshopWelcome to python workshop
Welcome to python workshop
 
Aspdot
AspdotAspdot
Aspdot
 
Python Basics by Akanksha Bali
Python Basics by Akanksha BaliPython Basics by Akanksha Bali
Python Basics by Akanksha Bali
 
C cpluplus 2
C cpluplus 2C cpluplus 2
C cpluplus 2
 
Zero to Hero - Introduction to Python3
Zero to Hero - Introduction to Python3Zero to Hero - Introduction to Python3
Zero to Hero - Introduction to Python3
 
C
CC
C
 
bhaskars.pptx
bhaskars.pptxbhaskars.pptx
bhaskars.pptx
 
1. PGA2.0-Python Programming-Intro to Python.pptx
1. PGA2.0-Python Programming-Intro to Python.pptx1. PGA2.0-Python Programming-Intro to Python.pptx
1. PGA2.0-Python Programming-Intro to Python.pptx
 
Python Course In Chandigarh
Python Course In ChandigarhPython Course In Chandigarh
Python Course In Chandigarh
 
prakash ppt (2).pdf
prakash ppt (2).pdfprakash ppt (2).pdf
prakash ppt (2).pdf
 
Lecture1_introduction to python.pptx
Lecture1_introduction to python.pptxLecture1_introduction to python.pptx
Lecture1_introduction to python.pptx
 
Chapter 01 Introduction to Java by Tushar B Kute
Chapter 01 Introduction to Java by Tushar B KuteChapter 01 Introduction to Java by Tushar B Kute
Chapter 01 Introduction to Java by Tushar B Kute
 
web programming UNIT VIII python by Bhavsingh Maloth
web programming UNIT VIII python by Bhavsingh Malothweb programming UNIT VIII python by Bhavsingh Maloth
web programming UNIT VIII python by Bhavsingh Maloth
 
Python Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | EdurekaPython Basics | Python Tutorial | Edureka
Python Basics | Python Tutorial | Edureka
 
C programming language tutorial
C programming language tutorialC programming language tutorial
C programming language tutorial
 
SE-IT JAVA LAB OOP CONCEPT
SE-IT JAVA LAB OOP CONCEPTSE-IT JAVA LAB OOP CONCEPT
SE-IT JAVA LAB OOP CONCEPT
 
c++ UNIT II.pptx
c++ UNIT II.pptxc++ UNIT II.pptx
c++ UNIT II.pptx
 
Static abstract members nelle interfacce di C# 11 e dintorni di .NET 7.pptx
Static abstract members nelle interfacce di C# 11 e dintorni di .NET 7.pptxStatic abstract members nelle interfacce di C# 11 e dintorni di .NET 7.pptx
Static abstract members nelle interfacce di C# 11 e dintorni di .NET 7.pptx
 
Basic concept of Python.pptx includes design tool, identifier, variables.
Basic concept of Python.pptx includes design tool, identifier, variables.Basic concept of Python.pptx includes design tool, identifier, variables.
Basic concept of Python.pptx includes design tool, identifier, variables.
 
Cs1123 11 pointers
Cs1123 11 pointersCs1123 11 pointers
Cs1123 11 pointers
 

Recently uploaded

會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
中 央社
 

Recently uploaded (20)

MOOD STABLIZERS DRUGS.pptx
MOOD     STABLIZERS           DRUGS.pptxMOOD     STABLIZERS           DRUGS.pptx
MOOD STABLIZERS DRUGS.pptx
 
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community PartnershipsSpring gala 2024 photo slideshow - Celebrating School-Community Partnerships
Spring gala 2024 photo slideshow - Celebrating School-Community Partnerships
 
Observing-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxObserving-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptx
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
 
Major project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategiesMajor project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategies
 
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptxAnalyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
Analyzing and resolving a communication crisis in Dhaka textiles LTD.pptx
 
Book Review of Run For Your Life Powerpoint
Book Review of Run For Your Life PowerpointBook Review of Run For Your Life Powerpoint
Book Review of Run For Your Life Powerpoint
 
ANTI PARKISON DRUGS.pptx
ANTI         PARKISON          DRUGS.pptxANTI         PARKISON          DRUGS.pptx
ANTI PARKISON DRUGS.pptx
 
DEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUM
DEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUMDEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUM
DEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUM
 
Climbers and Creepers used in landscaping
Climbers and Creepers used in landscapingClimbers and Creepers used in landscaping
Climbers and Creepers used in landscaping
 
e-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopale-Sealing at EADTU by Kamakshi Rajagopal
e-Sealing at EADTU by Kamakshi Rajagopal
 
UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024
 
Andreas Schleicher presents at the launch of What does child empowerment mean...
Andreas Schleicher presents at the launch of What does child empowerment mean...Andreas Schleicher presents at the launch of What does child empowerment mean...
Andreas Schleicher presents at the launch of What does child empowerment mean...
 
The Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDFThe Story of Village Palampur Class 9 Free Study Material PDF
The Story of Village Palampur Class 9 Free Study Material PDF
 
Graduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptxGraduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptx
 
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
TỔNG HỢP HƠN 100 ĐỀ THI THỬ TỐT NGHIỆP THPT TOÁN 2024 - TỪ CÁC TRƯỜNG, TRƯỜNG...
 
Scopus Indexed Journals 2024 - ISCOPUS Publications
Scopus Indexed Journals 2024 - ISCOPUS PublicationsScopus Indexed Journals 2024 - ISCOPUS Publications
Scopus Indexed Journals 2024 - ISCOPUS Publications
 
When Quality Assurance Meets Innovation in Higher Education - Report launch w...
When Quality Assurance Meets Innovation in Higher Education - Report launch w...When Quality Assurance Meets Innovation in Higher Education - Report launch w...
When Quality Assurance Meets Innovation in Higher Education - Report launch w...
 
An overview of the various scriptures in Hinduism
An overview of the various scriptures in HinduismAn overview of the various scriptures in Hinduism
An overview of the various scriptures in Hinduism
 
How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17
 

Python Training in Chandigarh(Mohali)

  • 2. About us We Are The Best Web Designing Institutes In Chandigarh Providing World Class Web Designing Classes Mohali Especially To Learners, Housewives & Other Who Are Looking For Web Designing Classes. We Have Taught More Than 6000+ Students In The Past 10 Years. After Completing Web Designing Institute In Mohali ,Many Facilities Are Provided . You Will Be Able To Build Faster & 100% Responsive Website That Deliver Better Results. You Will Get Assured Job After Completing Your Course. Web Designing Training In Mohali. 2
  • 3. 3 Filename, preferred extension is py User Program
  • 4. Interacting with Python Programs • Python program communicates its results to user using print • Most useful programs require information from users – Name and age for a travel reservation system • Python 3 uses input to read user input as a string (str) 4
  • 5. input • Take as argument a string to print as a prompt • Returns the user typed value as a string – details of how to process user string later 5 IN[1]: IN[2]: IN[3]: ( )
  • 6. Elements of Python • A Python program is a sequence of definitions and commands (statements) • Commands manipulate objects • Each object is associated with a Type • Type: – A set of values – A set of operations on these values • Expressions: An operation (combination of objects and operators) 6
  • 7. Types in Python • int – Bounded integers, e.g. 732 or -5 • float – Real numbers, e.g. 3.14 or 2.0 • long – Long integers with unlimited precision • str – Strings, e.g. ‘hello’ or ‘C’ 7
  • 8. Types in Python • Scalar – Indivisible objects that do not have internal structure – int (signed integers), float (floating point), bool (Boolean), NoneType • NoneType is a special type with a single value • The value is called None • Non-Scalar – Objects having internal structure – str (strings) 8
  • 9. Type Conversion Examples 9 Note that float to int conversion is truncation, not rounding off
  • 11. Operators • Arithmetic • Comparison • Assignment • Logical • Bitwise • Membership • Identity Jan-23 Programming 11 + - * // / % ** == != > < >= <= = += -= *= //= /= %= **= and or not in not in is is not & | ^ ~ >> <<
  • 12. Variables • A name associated with an object • Assignment used for binding m = 64; c = ‘Acads’; f = 3.1416; • Variables can change their bindings f = 2.7183; 12 64 Acads 3.1416 2.7183 m c f
  • 13. Multiple Assignments • Python allows multiple assignments x, y = 10, 20 • Evaluation of multiple assignment statement: – All the expressions on the RHS of the = are first evaluated before any binding happens. – Values of the expressions are bound to the corresponding variable on the LHS. x, y = 10, 20 x, y = y+1, x+1 13 Binds x to 10 and y to 20 x is bound to 21 and y to 11 at the end of the program
  • 14. Binary Operations 14 Op Meaning Example Remarks + Addition 9+2 is 11 9.1+2.0 is 11.1 - Subtraction 9-2 is 7 9.1-2.0 is 7.1 * Multiplication 9*2 is 18 9.1*2.0 is 18.2 / Division 9/2 is 4.25 In Python3 9.1/2.0 is 4.55 Real div. // Integer Division 9//2 is 4 % Remainder 9%2 is 1
  • 15. Web Designing Training in Chandigarh(Mohali) Address: Plot No C-133, near Gold Gym, Phase-8, Sahibzada Ajit Singh Nagar, 160055 Phone: +91 93562-55522 Website: http://excellenceacademy.co.in/ 15