.
Use the theorem:
In any triangle, the angle bisector divides the side to which it is drawn, in two segments proportional to the ratio of two other sides of a triangle
(See the lesson On what segments the angle bisector divides the side of a triangle in this site).
So, |PR| = 15x, |PQ| = 9x, where x is an unknown common measure of the segments PR and PQ.
Thus for the perimeter you have
15x + 9x + (15+9) = 40 ====>
24x = 40 - (15+9) = 16 ====> x = = .
Then |RL| = 15x = = 10 and |PQ| = 9x = = 6.
Answer. |PQ| = 6.
Solved.
The key to the solution is the theorem referred above.