firstly, a galvanometer measures current, so the pointer will deflect in the direction of current.
now, when X rotates, there is relative motion between the magnet inside the galvanometer and the conductive wire, so by faraday's law there will be some induced current in the circuit. according to the diagram and by lenz's law, the anticlockwise rotation of galvanometer X means that we would like to push the galvanometer back in the other direction, using induced currents. using right hand rule, we can thus see that the current induced would need to be from the positive terminal of X to the negative of Y. hence, the current will flow from negative to positive in Y; this would mean that the pointer is deflected towards the left. so, C and D are the only remaining options.
now a motor is just something that converts electrical energy to mechanical energy. in essence this is what's happening; the current through Y is being converted to kinetic energy to oppose the motion of X. this is kind of confusing on purpose, because it seems like Y is acting like a generator, converting the kinetic energy of X into some current; however, it is X that is the generator, as the kinetic energy of the rotation is turned into the current through induction, and then Y converts this current back into kinetic energy through opposing the motion of X.