UPS’s stock surges after profit beat by the widest margin in more than four years.