At a certain time of day, the angle of elevation is 40°. To the nearest foot, find the height of a tree whose shadow is 31 feet long.