0% found this document useful (0 votes)
10 views14 pages

L01S06

Uploaded by

rahma022566.18
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views14 pages

L01S06

Uploaded by

rahma022566.18
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

Python

Programming
Course
Level 1 session 6
CONTENTS OF TODAY’S SESSION

. Python operator definition

. Arithmetic operators

. Assignment operators

. Comparison operators

. logical operators
Python operator :

is a symbol that performs an


operation on one or more
operands. An operand is a
variable or a value on which we
perform the operation.
1
Arithmetic operators
Arithmetic operators
- Arithmetic operators are used with numeric values to perform common mathematical operations:

+ for addition - For subtraction * For multiplication

/ for division % for modulus ** for powering


2
Assignment operators
Assignment operators
- Assignment operators are used to assign values to variables using equal operator :

+= for addition -= For subtraction *= For multiplication

/= for division %= for modulus **= for powering


3
Comparison operators
Comparison operators
- Comparison operators are used to compare two values and the result will be true or false:

== equal != not equal > greater than

< less than >= greater than or = <= less than or =


4
Logical operators
Logical operators
- Logical operators are used to combine conditional statements:

And
or not

Returns True if both Returns True if one of Reverse the result, returns
statements are true the statements is true False if the result is true
5
Practice time
Practice time

https://quizizz.com/admin/quiz/5d2bc
01e504efd001b4bf1b2/python-
operators

Now we can solve this quiz ☺


Good luck
THANKS!
http://stemzone.online

https://www.facebook.com/S
temzone2022

CREDITS: This presentation template was


created by Slidesgo, including icons by
Flaticon, and infographics & images by
Freepik.

You might also like