So for finding vector having magnitude = 1 and direction same as q (i.e parallel to q)
we have to find unit vector along with q
i.e
Now find a vector which has the magnitude of p and Is parallel to q
we have multiply magnitude of p with a unit vector of q
i.e vector needed=