Thanks for the replies guys.
I asked my dad how to this.
First off, current flows from high potential to low potential. Which is something I didn't know.
For part a, for the 5kΩ resistor, V=5-0(At the ground point V=0, something else I didn't know). So V=5V, R=5000Ω. Therefore, I=V/R=5/5000=0.001A. Since point X is at 5V (higher potential) and ground is at 0V (lower potential), the current is flowing from X to ground, therefore, current is moving in direction P.
For part a, for the 2kΩ resistor, V=0--3. So V=3V, R=2000kΩ. Therefore I=V/R=3/2000=0.0015A. Since ground is at 0V (higher potential) and point Y is at -3V (lower potential), the current is flowing from ground to Y, therefore, current is moving in direction P.
For part b, I applied the same theory (without ground of course) but I got an answer different to that in the worked solutions. I think the solutions may be wrong, then again, there's a higher probability I'm wrong.