Yes, a math problem can have two answers — it depends on the type of question.
For example, quadratic equations like
x² = 9
have two answers: x = +3 and x = –3.
In trigonometry, equations like sin x = 0.5 also have multiple solutions within a range.
But some problems (like 2 + 2) always have only one answer.

