Well, add up all the forces (using vector addition) to find out what the net force is acting on the object, call it .

i.e. .

For part (a), if the angle of is along the y-axis, or if its magnitude is zero, then the object will stay on the y-axis.

For part (b), apply a force of the same magnitude but opposite direction (that is, apply ) to allow the object to continue along the y-axis at its original speed.