Continue to research primary sources as you evaluate various aspects of this path.
Obligated service is 10 years, and the counter for that starts after
flight training, which might be roughly 2 years (I am familiar with Navy, but service obligation start times and flight training length work roughly similarly there).
Learn what it takes to become a pilot. These skilled professionals deploy to wherever there’s a need as fighters, trainers, bombers, advisers and more.
For AF doctor, there are the obligated service years for USAFA, for med school and residency, and the counter starts after residency years. It can be many years down the road before obligated service requirements are complete. These are only very broad brush strokes. Leaving out a lot of detail. But the takeaway is the counter can start waaaay down the road. It’s a great path, but you essentially have to know you want to be an AF doc for a long time.
The good news is you get briefs about all these things at USAFA, you’ll be exposed to officers in various officer specialties and watch upperclass work through their decisions. And, you can walk away anytime during the first 2 years without incurring a service obligation.