πŸ“Š Python
Q. Which method is used to compare two Python objects?
  • (A) __str__
  • (B) __repr__
  • (C) __eq__
  • (D) __cmp__
πŸ’¬ Discuss
βœ… Correct Answer: (C) __eq__

Explanation: The `__eq__` method is used to compare two objects for equality using `==`.

Explanation by: Mr. Dubey
The `__eq__` method is used to compare two objects for equality using `==`.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
42
Total Visits
πŸ“½οΈ
8 mo ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
97%
Success Rate