Solveeit Logo

Question

Quantitative Aptitude Question on Algebra

The number of distinct integer solutions (x, y) of the equation |x + y| + |x - y| = 2, is

Answer

We are given the equation:
x+y+xy=2|x + y| + |x - y| = 2

Case 1: x+y0x + y \ge 0 and xy0x - y \ge 0. In this case, the equation becomes:
(x+y)+(xy)=2    2x=2    x=1(x + y) + (x - y) = 2 \implies 2x = 2 \implies x = 1
Substitute x=1x = 1 into x+y0x + y \ge 0 and xy0x - y \ge 0:
1+y0and1y01 + y \ge 0 \quad \text{and} \quad 1 - y \ge 0
Solving these inequalities gives:
y1andy1y \ge -1 \quad \text{and} \quad y \le 1
Thus, yy can be 1,0,1-1, 0, 1, giving 3 solutions for x=1x = 1.

Case 2: x+y0x + y \ge 0 and xy0x - y \le 0. In this case, the equation becomes:
(x+y)+(x+y)=2    2y=2    y=1(x + y) + (-x + y) = 2 \implies 2y = 2 \implies y = 1
Substitute y=1y = 1 into x+y0x + y \ge 0 and xy0x - y \le 0:
x+10andx10x + 1 \ge 0 \quad \text{and} \quad x - 1 \le 0
Solving these inequalities gives:
x1andx1x \ge -1 \quad \text{and} \quad x \le 1
Thus, xx can be 1,0,1-1, 0, 1, giving 3 solutions for y=1y = 1.

Case 3: x+y0x + y \le 0 and xy0x - y \ge 0. In this case, the equation becomes:
(xy)+(xy)=2    2y=2    y=1(-x - y) + (x - y) = 2 \implies -2y = 2 \implies y = -1
Substitute y=1y = -1 into x+y0x + y \le 0 and xy0x - y \ge 0:
x10andx+10x - 1 \le 0 \quad \text{and} \quad x + 1 \ge 0
Solving these inequalities gives:
x1andx1x \le 1 \quad \text{and} \quad x \ge -1
Thus, xx can be 1,0,1-1, 0, 1, giving 3 solutions for y=1y = -1.

Case 4: x+y0x + y \le 0 and xy0x - y \le 0. In this case, the equation becomes:
(xy)+(x+y)=2    2x=2    x=1(-x - y) + (-x + y) = 2 \implies -2x = 2 \implies x = -1
Substitute x=1x = -1 into x+y0x + y \le 0 and xy0x - y \le 0:
1+y0and1y0-1 + y \le 0 \quad \text{and} \quad -1 - y \le 0
Solving these inequalities gives:
y1andy1y \le 1 \quad \text{and} \quad y \ge -1
Thus, yy can be 1,0,1-1, 0, 1, giving 3 solutions for x=1x = -1.

Conclusion: From all four cases, we get a total of 3+3+3+3=123 + 3 + 3 + 3 = 12 distinct integer solutions. Therefore, the correct answer is 12.

Explanation

Solution

We are given the equation:
x+y+xy=2|x + y| + |x - y| = 2

Case 1: x+y0x + y \ge 0 and xy0x - y \ge 0. In this case, the equation becomes:
(x+y)+(xy)=2    2x=2    x=1(x + y) + (x - y) = 2 \implies 2x = 2 \implies x = 1
Substitute x=1x = 1 into x+y0x + y \ge 0 and xy0x - y \ge 0:
1+y0and1y01 + y \ge 0 \quad \text{and} \quad 1 - y \ge 0
Solving these inequalities gives:
y1andy1y \ge -1 \quad \text{and} \quad y \le 1
Thus, yy can be 1,0,1-1, 0, 1, giving 3 solutions for x=1x = 1.

Case 2: x+y0x + y \ge 0 and xy0x - y \le 0. In this case, the equation becomes:
(x+y)+(x+y)=2    2y=2    y=1(x + y) + (-x + y) = 2 \implies 2y = 2 \implies y = 1
Substitute y=1y = 1 into x+y0x + y \ge 0 and xy0x - y \le 0:
x+10andx10x + 1 \ge 0 \quad \text{and} \quad x - 1 \le 0
Solving these inequalities gives:
x1andx1x \ge -1 \quad \text{and} \quad x \le 1
Thus, xx can be 1,0,1-1, 0, 1, giving 3 solutions for y=1y = 1.

Case 3: x+y0x + y \le 0 and xy0x - y \ge 0. In this case, the equation becomes:
(xy)+(xy)=2    2y=2    y=1(-x - y) + (x - y) = 2 \implies -2y = 2 \implies y = -1
Substitute y=1y = -1 into x+y0x + y \le 0 and xy0x - y \ge 0:
x10andx+10x - 1 \le 0 \quad \text{and} \quad x + 1 \ge 0
Solving these inequalities gives:
x1andx1x \le 1 \quad \text{and} \quad x \ge -1
Thus, xx can be 1,0,1-1, 0, 1, giving 3 solutions for y=1y = -1.

Case 4: x+y0x + y \le 0 and xy0x - y \le 0. In this case, the equation becomes:
(xy)+(x+y)=2    2x=2    x=1(-x - y) + (-x + y) = 2 \implies -2x = 2 \implies x = -1
Substitute x=1x = -1 into x+y0x + y \le 0 and xy0x - y \le 0:
1+y0and1y0-1 + y \le 0 \quad \text{and} \quad -1 - y \le 0
Solving these inequalities gives:
y1andy1y \le 1 \quad \text{and} \quad y \ge -1
Thus, yy can be 1,0,1-1, 0, 1, giving 3 solutions for x=1x = -1.

Conclusion: From all four cases, we get a total of 3+3+3+3=123 + 3 + 3 + 3 = 12 distinct integer solutions. Therefore, the correct answer is 12.