Operators in Python - What is Operator - Types of Operator in Python - Python Tutorial, Learn Python

What are operators in python?

Operators are special symbols in Python that carry out arithmetic or logical computation. The value that the operator operates on is called the operand.

 

Types of Operator -

 

Arithmetic operators: - Arithmetic operators are used to perform mathematical operations like addition, subtraction, multiplication etc.

Assignment operators: - Assignment operators are used in Python to assign values to variables.

 

Comparison operators: - Comparison operators are used to compare values. It either returns True or False according to the condition.

 

Logical operators: - Logical operators are the and, or, not operators.

 

Identity operators: - is and is not are the identity operators in Python. They are used to check if two values (or variables) are located on the same part of the memory. Two variables that are equal does not imply that they are identical.

 

Membership operators: - in and not in are the membership operators in Python. They are used to test whether a value or variable is found in a sequence (string, list, tuple, set and dictionary).

 

Bitwise operators: - Bitwise operators act on operands as if they were string of binary digits. It operates bit by bit, hence the name.

 

 

C Programming Tutorials:-http://bit.ly/2AQosMH

C++ Programming Tutorials:-http://bit.ly/2FVDyGw

Youtube;-http://bit.ly/2BTyIp3

Website:-http://bit.ly/2G3AVCJ

 

 

 

374 views
0 faves
0 comments
Uploaded on December 6, 2018