MCQs > IT & Programming > Python > Output of following code? class Example: def __init__(self, i = 2, j = 3): self.i = i self.j = j def __str__(self): return'Example' def __eq__(self, other): return self.i * self.j == other.i * other.j def main(): x = Example(1, 2) y = Example(2, 1) print(x == y) main()

Python MCQs

dWhat will be the output of following code? class Example: def __init__(self, i = 2, j = 3): self.i = i self.j = j def __str__(self): return"Example" def __eq__(self, other): return self.i * self.j == other.i * other.j def main(): x = Example(1, 2) y = Example(2, 1) print(x == y) main()

Answer

Correct Answer: True

Explanation:

Note: This Question is unanswered, help us to find answer for this one

Python Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

Python Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it