PYEONGCHANG, South Korea — Shaun White’s train of thought was briefly derailed on Tuesday by the music blaring at Phoenix Snow Park. The song was “Ain’t No Mountain High Enough,” and the lyrics seemed fitting: “No wind, no rain, nor winter’s cold can stop me, baby … ”

White, 31, had just produced two near-perfect halfpipe runs to lead the field in the qualifying event. On Wednesday, he proceeded to outdo himself and everyone else in the final. He won his third gold medal in four trips to the Olympics with a masterly final run that earned him 97.75 points and a narrow victory over the Japanese teenager Ayumu Hirano, who had posted a 95.25 on his second run.

White’s 11 competitors averaged 21.9 years of age, led by Hirano, 19, who last month became the first snowboarder to pop back-to-back 1440s, or four revolutions in competition. Before he succeeded, he had several mishaps, including slamming into the wall on a double cork 1440 and injuring his left knee and liver.

When White was Hirano’s age, he won the first of his two Olympic titles with a run that included two 1080s.