We have, ∣z∣−z=1+2i
If z=x+iy, then this equation reduces to ∣x+iy∣−(x+iy)=1+2i ⇒(x2+y2−x)+(−iy)=1+2i
On comparing real and imaginary parts of both sides of this equation, we get x2+y2−x=1 ⇒x2+y2=1+x ⇒x2+y2=(1+x)2 ⇒x2+y2=1+x2+2x ⇒y2=1+2x ...(i)
and −y=2 ⇒y=−2
Putting this value in Eq. (i), we get (−2)2=1+2x ⇒2x=3 ⇒x=23
Hence, z=x+iy =23−2i