SlideShare una empresa de Scribd logo
1 de 16
Descargar para leer sin conexión
Python Training in
Chandigarh(Mohali)
Excellence Academy Is The Renowned & Best Python Training
Institute In Chandigarh That Provides 100% Job-Oriented
.Python Training Institute In Mohali Our Course Is Designed
Especially For Students, Housewives & Other Who Are Looking
For Python Training In Chandigarh.
 code or source code: The sequence of instructions in a program.
 syntax: The set of legal structures and commands that can be
used in a particular programming language.
 output: The messages printed to the user by a program.
 console: The text box onto which output is printed.
 Some source code editors pop up the console as an external window,
and others contain their own console window.
Programming basics
2
Compiling and interpreting
 Many languages require you to compile (translate) your program
into a form that the machine understands.
compile execute
 Python is instead directly interpreted into machine instructions.
interpret
output
source code
Hello.java
byte code
Hello.class
output
source code
Hello.py
3
The Python Interpreter
•Python is an interpreted
language
•The interpreter provides
an interactive environment
to play with the language
•Results of expressions are
printed on the screen
>>> 3 + 7
10
>>> 3 < 15
True
>>> 'print me'
'print me'
>>> print 'print me'
print me
>>>
Expressions
5
 expression: A data value or set of operations to compute a value.
Examples: 1 + 4 * 3
42
 Arithmetic operators we will use:
+ - * /
%
**
addition, subtraction/negation, multiplication, division
modulus, a.k.a. remainder
exponentiation
 precedence: Order in which operations are computed.
 * / % ** have a higher precedence than + -
1 + 3 * 4 is 13
 Parentheses can be used to force a certain order of evaluation.
(1 + 3) * 4 is 16
Integer division
6
 When we divide integers with / , the quotient is also an integer.
3 52
4 ) 14 27 ) 1425
12 135
2 75
54
21
 More examples:
 35 / 5 is 7
 84 / 10 is 8
 156 / 100 is 1
 The % operator computes the remainder from a division of integers.
3
4 ) 14
12
2
43
5 ) 218
20
18
15
3
Real numbers
7
 Python can also manipulate real numbers.
 Examples: 6.022 -15.9997 42.0 2.143e17
 The operators + - * / % ** ( ) all work for real numbers.
 The / produces an exact answer: 15.0 / 2.0 is 7.5
 The same rules of precedence also apply to real numbers:
Evaluate ( ) before * / % before + -
 When integers and reals are mixed, the result is a real number.
 Example: 1 / 2.0 is 0.5
 The conversion occurs on a per-operator basis.
7 / 3 * 1.2 + 3 / 2
2 * 1.2 + 3 / 2
2.4 + 3 / 2
2.4 + 1
3.
4
8
Math commands
 Python has useful commands (or called functions) for performing
calculations.
 To use many of these commands, you must write the following at
the top of your Python program:
from math import *
Command name Description
abs(value) absolute value
ceil(value) rounds up
cos(value) cosine, in radians
floor(value) rounds down
log(value) logarithm, base e
log10(value) logarithm, base 10
max(value1, value2) larger of two values
min(value1, value2) smaller of two values
round(value) nearest whole number
sin(value) sine, in radians
sqrt(value) square root
Constant Description
e 2.7182818...
pi 3.1415926...
Numbers: Floating Point
 int(x) converts x to
an integer
 float(x) converts x
to a floating point
 The interpreter
shows
a lot of digits
>>> 1.23232
1.2323200000000001
>>> print 1.23232
1.23232
>>> 1.3E7
13000000.0
>>> int(2.0)
2
>>> float(2)
2.0
 A variable that has been given a value can be used in expressions.
x + 4 is 9
 Exercise: Evaluate the quadratic equation for a given a, b, and c.
10
Variables
 variable: A named piece of memory that can store a value.
 Usage:
 Compute an expression's result,
 store that result into a variable,
 and use that variable later in the program.
 assignment statement: Stores a value into a variable.
 Syntax:
name = value
 Examples: x = 5
gpa = 3.14
x 5 gpa 3.14
Example
>>> x = 7
>>> x
7
>>> x+7
14
>>> x = 'hello'
>>> x
'hello'
>>>
 print : Produces text output on the console.
 Syntax:
print "Message"
print Expression
 Prints the given text message or expression value on the console, and
moves the cursor down to the next line.
print Item1, Item2, ..., ItemN
 Prints several messages and/or expressions on the same line.
 Examples:
print "Hello, world!"
age = 45
print "You have", 65 - age, "years until retirement"
Output:
Hello, world!
You have 20 years until retirement
12
print
Example: print Statement
>>> print 'hello'
hello
>>> print 'hello', 'there'
hello there
•Elements separated by
commas print with a space
between them
•A comma at the end of the
statement (print ‘hello’,)
will not print a newline
character
 input : Reads a number from user input.
 You can assign (store) the result of input into a variable.
 Example:
age = input("How old are you? ")
print "Your age is", age
print "You have", 65 - age, "years until retirement"
Output:
How old are you? 53
Your age is 53
You have 12 years until retirement
14
 Exercise: Write a Python program that prompts the user for
his/her amount of money, then reports how many Nintendo Wiis
the person can afford, and how much more money he/she will
need to afford an additional Wii.
input
Input: Example
print "What's your name?"
name = raw_input("> ")
print "What year were you born?"
birthyear = int(raw_input("> "))
print "Hi “, name, “!”, “You are “, 2016 – birthyear
% python input.py
What's your name?
> Michael
What year were you born?
>1980
Hi Michael! You are 31
Thank You
Address: Plot No C-133, near Gold Gym, Phase-8,
Sahibzada Ajit Singh Nagar, 160055
Phone: +91 93562-55522
Website: http://excellenceacademy.co.in/

Más contenido relacionado

Similar a Python Training Course in Chandigarh(Mohali)

Basic Concepts in Python
Basic Concepts in PythonBasic Concepts in Python
Basic Concepts in PythonSumit Satam
 
C++ and OOPS Crash Course by ACM DBIT | Grejo Joby
C++ and OOPS Crash Course by ACM DBIT | Grejo JobyC++ and OOPS Crash Course by ACM DBIT | Grejo Joby
C++ and OOPS Crash Course by ACM DBIT | Grejo JobyGrejoJoby1
 
python-online&offline-training-in-kphb-hyderabad (1) (1).pdf
python-online&offline-training-in-kphb-hyderabad (1) (1).pdfpython-online&offline-training-in-kphb-hyderabad (1) (1).pdf
python-online&offline-training-in-kphb-hyderabad (1) (1).pdfKosmikTech1
 
02a fundamental c++ types, arithmetic
02a   fundamental c++ types, arithmetic 02a   fundamental c++ types, arithmetic
02a fundamental c++ types, arithmetic Manzoor ALam
 
Python programming workshop session 2
Python programming workshop session 2Python programming workshop session 2
Python programming workshop session 2Abdul Haseeb
 
Lecture # 1 - Introduction Revision - 1 OOPS.pptx
Lecture # 1 - Introduction  Revision - 1 OOPS.pptxLecture # 1 - Introduction  Revision - 1 OOPS.pptx
Lecture # 1 - Introduction Revision - 1 OOPS.pptxSanaullahAttariQadri
 
Programming in C by SONU KUMAR.pptx
Programming in C by SONU KUMAR.pptxProgramming in C by SONU KUMAR.pptx
Programming in C by SONU KUMAR.pptxSONU KUMAR
 
C++ Tutorial.docx
C++ Tutorial.docxC++ Tutorial.docx
C++ Tutorial.docxPinkiVats1
 
the refernce of programming C notes ppt.pptx
the refernce of programming C notes ppt.pptxthe refernce of programming C notes ppt.pptx
the refernce of programming C notes ppt.pptxAnkitaVerma776806
 
4. programing 101
4. programing 1014. programing 101
4. programing 101IEEE MIU SB
 
Complete C++ programming Language Course
Complete C++ programming Language CourseComplete C++ programming Language Course
Complete C++ programming Language CourseVivek chan
 

Similar a Python Training Course in Chandigarh(Mohali) (20)

Python Lecture 2
Python Lecture 2Python Lecture 2
Python Lecture 2
 
Basic Concepts in Python
Basic Concepts in PythonBasic Concepts in Python
Basic Concepts in Python
 
3 algorithm-and-flowchart
3 algorithm-and-flowchart3 algorithm-and-flowchart
3 algorithm-and-flowchart
 
C++ lecture 01
C++   lecture 01C++   lecture 01
C++ lecture 01
 
C++ and OOPS Crash Course by ACM DBIT | Grejo Joby
C++ and OOPS Crash Course by ACM DBIT | Grejo JobyC++ and OOPS Crash Course by ACM DBIT | Grejo Joby
C++ and OOPS Crash Course by ACM DBIT | Grejo Joby
 
python-online&offline-training-in-kphb-hyderabad (1) (1).pdf
python-online&offline-training-in-kphb-hyderabad (1) (1).pdfpython-online&offline-training-in-kphb-hyderabad (1) (1).pdf
python-online&offline-training-in-kphb-hyderabad (1) (1).pdf
 
Spsl iv unit final
Spsl iv unit  finalSpsl iv unit  final
Spsl iv unit final
 
Spsl iv unit final
Spsl iv unit  finalSpsl iv unit  final
Spsl iv unit final
 
02a fundamental c++ types, arithmetic
02a   fundamental c++ types, arithmetic 02a   fundamental c++ types, arithmetic
02a fundamental c++ types, arithmetic
 
Python programming workshop session 2
Python programming workshop session 2Python programming workshop session 2
Python programming workshop session 2
 
Lecture # 1 - Introduction Revision - 1 OOPS.pptx
Lecture # 1 - Introduction  Revision - 1 OOPS.pptxLecture # 1 - Introduction  Revision - 1 OOPS.pptx
Lecture # 1 - Introduction Revision - 1 OOPS.pptx
 
Python basics
Python basicsPython basics
Python basics
 
Programming in C by SONU KUMAR.pptx
Programming in C by SONU KUMAR.pptxProgramming in C by SONU KUMAR.pptx
Programming in C by SONU KUMAR.pptx
 
Introduction to Procedural Programming in C++
Introduction to Procedural Programming in C++Introduction to Procedural Programming in C++
Introduction to Procedural Programming in C++
 
C++ Tutorial.docx
C++ Tutorial.docxC++ Tutorial.docx
C++ Tutorial.docx
 
the refernce of programming C notes ppt.pptx
the refernce of programming C notes ppt.pptxthe refernce of programming C notes ppt.pptx
the refernce of programming C notes ppt.pptx
 
4. programing 101
4. programing 1014. programing 101
4. programing 101
 
Python
PythonPython
Python
 
C++
C++C++
C++
 
Complete C++ programming Language Course
Complete C++ programming Language CourseComplete C++ programming Language Course
Complete C++ programming Language Course
 

Último

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAssociation for Project Management
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...Sapna Thakur
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3JemimahLaneBuaron
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactPECB
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfchloefrazer622
 

Último (20)

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
 
Advance Mobile Application Development class 07
Advance Mobile Application Development class 07Advance Mobile Application Development class 07
Advance Mobile Application Development class 07
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
 

Python Training Course in Chandigarh(Mohali)

  • 1. Python Training in Chandigarh(Mohali) Excellence Academy Is The Renowned & Best Python Training Institute In Chandigarh That Provides 100% Job-Oriented .Python Training Institute In Mohali Our Course Is Designed Especially For Students, Housewives & Other Who Are Looking For Python Training In Chandigarh.
  • 2.  code or source code: The sequence of instructions in a program.  syntax: The set of legal structures and commands that can be used in a particular programming language.  output: The messages printed to the user by a program.  console: The text box onto which output is printed.  Some source code editors pop up the console as an external window, and others contain their own console window. Programming basics 2
  • 3. Compiling and interpreting  Many languages require you to compile (translate) your program into a form that the machine understands. compile execute  Python is instead directly interpreted into machine instructions. interpret output source code Hello.java byte code Hello.class output source code Hello.py 3
  • 4. The Python Interpreter •Python is an interpreted language •The interpreter provides an interactive environment to play with the language •Results of expressions are printed on the screen >>> 3 + 7 10 >>> 3 < 15 True >>> 'print me' 'print me' >>> print 'print me' print me >>>
  • 5. Expressions 5  expression: A data value or set of operations to compute a value. Examples: 1 + 4 * 3 42  Arithmetic operators we will use: + - * / % ** addition, subtraction/negation, multiplication, division modulus, a.k.a. remainder exponentiation  precedence: Order in which operations are computed.  * / % ** have a higher precedence than + - 1 + 3 * 4 is 13  Parentheses can be used to force a certain order of evaluation. (1 + 3) * 4 is 16
  • 6. Integer division 6  When we divide integers with / , the quotient is also an integer. 3 52 4 ) 14 27 ) 1425 12 135 2 75 54 21  More examples:  35 / 5 is 7  84 / 10 is 8  156 / 100 is 1  The % operator computes the remainder from a division of integers. 3 4 ) 14 12 2 43 5 ) 218 20 18 15 3
  • 7. Real numbers 7  Python can also manipulate real numbers.  Examples: 6.022 -15.9997 42.0 2.143e17  The operators + - * / % ** ( ) all work for real numbers.  The / produces an exact answer: 15.0 / 2.0 is 7.5  The same rules of precedence also apply to real numbers: Evaluate ( ) before * / % before + -  When integers and reals are mixed, the result is a real number.  Example: 1 / 2.0 is 0.5  The conversion occurs on a per-operator basis. 7 / 3 * 1.2 + 3 / 2 2 * 1.2 + 3 / 2 2.4 + 3 / 2 2.4 + 1 3. 4
  • 8. 8 Math commands  Python has useful commands (or called functions) for performing calculations.  To use many of these commands, you must write the following at the top of your Python program: from math import * Command name Description abs(value) absolute value ceil(value) rounds up cos(value) cosine, in radians floor(value) rounds down log(value) logarithm, base e log10(value) logarithm, base 10 max(value1, value2) larger of two values min(value1, value2) smaller of two values round(value) nearest whole number sin(value) sine, in radians sqrt(value) square root Constant Description e 2.7182818... pi 3.1415926...
  • 9. Numbers: Floating Point  int(x) converts x to an integer  float(x) converts x to a floating point  The interpreter shows a lot of digits >>> 1.23232 1.2323200000000001 >>> print 1.23232 1.23232 >>> 1.3E7 13000000.0 >>> int(2.0) 2 >>> float(2) 2.0
  • 10.  A variable that has been given a value can be used in expressions. x + 4 is 9  Exercise: Evaluate the quadratic equation for a given a, b, and c. 10 Variables  variable: A named piece of memory that can store a value.  Usage:  Compute an expression's result,  store that result into a variable,  and use that variable later in the program.  assignment statement: Stores a value into a variable.  Syntax: name = value  Examples: x = 5 gpa = 3.14 x 5 gpa 3.14
  • 11. Example >>> x = 7 >>> x 7 >>> x+7 14 >>> x = 'hello' >>> x 'hello' >>>
  • 12.  print : Produces text output on the console.  Syntax: print "Message" print Expression  Prints the given text message or expression value on the console, and moves the cursor down to the next line. print Item1, Item2, ..., ItemN  Prints several messages and/or expressions on the same line.  Examples: print "Hello, world!" age = 45 print "You have", 65 - age, "years until retirement" Output: Hello, world! You have 20 years until retirement 12 print
  • 13. Example: print Statement >>> print 'hello' hello >>> print 'hello', 'there' hello there •Elements separated by commas print with a space between them •A comma at the end of the statement (print ‘hello’,) will not print a newline character
  • 14.  input : Reads a number from user input.  You can assign (store) the result of input into a variable.  Example: age = input("How old are you? ") print "Your age is", age print "You have", 65 - age, "years until retirement" Output: How old are you? 53 Your age is 53 You have 12 years until retirement 14  Exercise: Write a Python program that prompts the user for his/her amount of money, then reports how many Nintendo Wiis the person can afford, and how much more money he/she will need to afford an additional Wii. input
  • 15. Input: Example print "What's your name?" name = raw_input("> ") print "What year were you born?" birthyear = int(raw_input("> ")) print "Hi “, name, “!”, “You are “, 2016 – birthyear % python input.py What's your name? > Michael What year were you born? >1980 Hi Michael! You are 31
  • 16. Thank You Address: Plot No C-133, near Gold Gym, Phase-8, Sahibzada Ajit Singh Nagar, 160055 Phone: +91 93562-55522 Website: http://excellenceacademy.co.in/