Why did the navy do away with the S-3 Viking? Often, I see that when a carrier group detects a sub it may be 100 miles, or more, away. Without the Viking, the only option is to send helos. They fly so slow that it takes forever to get there. Plus, when they get there they are essentially out of fuel.
The Vikings could respond much quicker, and could remain over the are much longer.
So, why did they do that?
When the Soviet Union fell, and they weren't talking about carriers escorting convoys across the Atlantic or striking on the Pacific side of the Soviet Union, they weren't as concerned about the ASW threat in regions which were outside the reach of land-based aviation. If they could always fly MPAs out of a land base to protect the carrier when there were submarines around, it was better to free up the space for strike aircraft on the carrier. A carrier strike group (CSG) includes at least a squadron of land based MPA. As they transitioned away from the P-3 to the P-8 things changed even more, because now the P-8 could refuel in midair. The result has been all kinds of interesting ways of sustaining MPA protection even further out from land bases.
It took a while to get rid of the S-3 entirely, though. In addition to their ASW role, they were pretty useful, having evolved into the "pickup truck" of fixed wing carrier based aviation. They carried a lot of really good sensors, so they had an ISR role, they also were useful as tankers, and even occasionally as light bombers carrying JDAMs and laser guided bombs, performing in a uniquely Navy-like role flying SUCAP. There's still a community of people who think it was a bad idea to take away carrier based, fixed wing ASW. So far they've been vetoed by those who think it's better to have more strikers.