There are 2 possible answers depending on whether the long segment is closer to A or B.
The ratio of 1:3 means there must be 4 equal parts of the line, 1 part in one segment and 3 parts in the other
One answer is:
(1/4)5 + (3/4)(-1) = 1/2
(1/4)8 + (3/4)4 = 5/4
i.e.
[(1/2),(5/4)]