Some states are losing teachers faster than they can train new ones. A decade of federal education data shows where the pressure is building.