Answer
(a) out of the page
(b) upward
Work Step by Step
We can write an expression for the force on the particle:
$F = q~(v\times B)$
To apply the right hand rule, we point the thumb in the direction of the positive charge and the index finger in the direction of the magnetic field.
(a) By the right hand rule, the magnetic field must be directed out of the page. Then the initial force on the particle is directed downward.
(b) By the right hand rule, if the particle were positively charged, the magnetic field would be directed downward. Then the initial force on the particle would be directed into the page. Since the particle is negatively charged, the magnetic field must be directed upward.