i’m pretty sure you set the perimeters equal to each other, it would look like 3x+8+3x+7+3x = 3x+3x+4x+2 and then you add the similar ones so it would look like 9x+15 = 10x+2 then you subtract the two from both sides and subject the 9x from both sides and get 13 = x
AB would be 47
BC = 46
AC = 39
PQ = 39
QR = 39
PR = 54
then you could double check
47+46+39 = 39+39+54
132 = 132