Answer
(a) The distance traveled is 5 m.
Displacement: $\Delta x=5m$
(b) The distance traveled is 2 m.
Displacement: $\Delta x=-2m$
Work Step by Step
(a) We know that
$Displacement \space of\space player A=final \space position- initial \space position$
$\implies Displacement \space of\space player A=5.0m-0m=5.0m$
(b) We know that
$Displacement \space of \space player B=Final \space position-Initial \space position$
We plug in the known values to obtain:
$Displacement \space of \space player B=5m-7m=-2.0m$