If -2,x,y and 28 are consecutive terms in AP. Find x and y

Let the common difference of the AP be d.

Then, from the given information, we have:

x = -2 + d (since -2 and x are consecutive terms)
y = x + d (since x and y are consecutive terms)
28 = y + d (since y and 28 are consecutive terms)

Substituting x = -2 + d into the equation for y, we get:

y = (-2 + d) + d
y = -2 + 2d

Substituting y = -2 + 2d into the equation for 28, we get:

28 = (-2 + 2d) + d
28 = -2 + 3d
30 = 3d
d = 10

Substituting d = 10 into the equations for x and y, we get:

x = -2 + 10 = 8
y = -2 + 2(10) = 18

Therefore, x = 8 and y = 18.