Arithmetic operators
operator Description example
+ (addition) Add two operands a+b
Subtract the right operand from the a-b
- (subtraction)
left
* (multiplication Multiply the both operands a*b
/ (division) Divide numerator by denominator a /b
% (module) Gives the remainder after division a%b
It calculates the power of first a ** b
** (exponential)
operands power to the second
Same as division but it gives the a // b
// (floor division) nearest whole number results after
division
identity operators
operator Description
is It will returns true if both variables are same object
is not It will returns true if both variables are not same object
Membership operators
operator Description
It will returns true if the sequence with specific value
In
present in the object
It will returns true if the sequence with specific value is not
not in
present in the object
logical operators
operator Description
If both the conditions meet the criteria(non zero)then the condition
&& (and)
becomes true
If any one the conditions meet the criteria(non zero)then the condition
|| (or)
becomes true
It is used for reverse result . if the condition Is true it gives false .if it is
! (not)
false it gives true