Which of the following is not a valid operator in Python?
2023
Which of the following is not a valid operator in Python?
- A.
==
- B.
=>
- C.
/ /
- D.
**
Attempted by 2541 students.
Show answer & explanation
Correct answer: B
Final answer: => / => is not a valid operator in Python.
'==' is the equality operator in Python (e.g., 3 == 3 is True).
'/' is true division and '//' is floor (integer) division (e.g., 7 / 2 == 3.5; 7 // 2 == 3).
'**' is the exponentiation operator (e.g., 2 ** 3 == 8).
'=>' is not a Python operator; using it in Python code will raise a SyntaxError. It is used in some other languages or contexts but not as a Python operator.