The foot of a 24 ft ladder is placed 6 ft from the base of a building, determine at what height the
ladder rests on the building.