According to the meaning of the question:
In Rt△APC, ∠ APC = 30 and PC=60, then:
From tan∠APC=AC/PC, we can get AC = PC * tan ∠ APC = 60 * tan 30 = 20 √ 3.
In Rt△BPC, ∠ BPC = 45, then BC=PC=60.
So: AB = AC+BC = 20 √ 3+60 ≈ 88.3m.
That is, the distance between teaching building A and office building B is 88.3 meters.