Remeber what z is! Z stands for a complex number in the form a+bi, where a and b are real, and i is an imaginary number. So, we can restate the question like:
(a+bi)^2=2i.
(a+bi)^2 can be expanded into a^2+2abi-b^2 (becase the sqaure of i is -1).
Therefore, a^2+2abi-b^2=2i. For this to be true, we see that the only way is for a^2 and b^2 to cancel out. Along with that, 2ab must equal to 2. Therefore, the options for a and b are 1 and -1.
Using combinations, we see that the complex numbers that satisfy this equation is: 1+i, -1+i, 1-i, -1-i.