# Not Equal Operator in Python : With Examples

Operators are used to perform various operations on variables and values. And our article is devoted to the different types of operators that are used in programming in python. Happy reading!

## Arithmetic operators in Python

They are used to perform general mathematical operations:

+ | responsible for addition | 1 + 3 |

— | responsible for subtraction | 7 — 4 |

* | responsible for multiplication | 3 * 2 |

/ | responsible for division | 8 / 4 |

% | finds the remainder of division | 5 % 3 |

** | raises a number to a power | 2 ** 3 |

## Assignment operators in Python

This type of operator is used when you want to assign a specific value to a variable. Here are some examples:

= | y = 8 | y = 8 |

+= | y += 8 | y = y + 8 |

-= | y -= 8 | y = y — 8 |

*= | y *= 8 | y = y * 8 |

/= | y /= 8 | y = y / 8 |

%= | y %= 8 | y = y % 8 |

//= | y //= 8 | y = y // 8 |

**= | y **= 8 | y = y ** 8 |

&= | y &= 8 | y = y & 8 |

|= | y |= 8 | y = y | 8 |

^= | y ^= 8 | y = y ^ 8 |

>>= | y >>= 8 | y = y >> 8 |

<<= | y <<= 8 | y = y << 8 |

## Comparison operators in Python

Here everything is simple: they are used to compare two expressions.

== | means equality | x == y |

!= | means inequality | x != y |

> | means more than | x > y |

< | means less than | x < y |

## Logical operators in Python

They are used to combine conditional statements:

is | Displays true if the variables are the same | a is b |

is not | Displays true, provided that the variables are different | a is not b |

## Bitwise operators in Python

Bitwise operators are used to work in bit (binary) format:

& | Operator I. Setting the bit to 1, provided that both bits are equal to the same. |

| | The Or operator. Set the bit to 1, provided that one bit equals one. |

^ | Operator Only or. Set the bit to 1, provided that only one bit equals one. |

~ | This statement reverses all bits. |

<< | This statement shifts to the left by the number of bits that were specified on the right. |

>> | This statement shifts to the right by the number of bits that were specified on the left. |