Hint- For solving we will compare the corresponding components of the vector and find the unknown values because two vectors will be equal if and only if their corresponding components are equal.
For finding the values of $x$ and $y$
\vec a = 2\hat i + 3\hat j = 2\hat i + 3\hat j + 0\hat k \\
\vec b = x\hat i + y\hat j = x\hat i + y\hat j + 0\hat k \\
Since, given in the question
$\vec a = \vec b$
So, comparing the corresponding components of the two given vectors
Thus, we get:
x = 2 and y = 3
Note- Any two vectors are equal if and only if both the magnitude of the vector and its direction are equal. If any of them fails to be the same, the vectors can’t be said to be equal. Also always remember that for equality of two vectors the best way is to compare the corresponding components.