Students who completed medical school in 2017 owed an average of nearly $191,000 in education debt, according to the Association of American Medical Colleges [PDF]. While steep, this investment can lead to hefty salaries—some of the highest paying in America, according to new reports compiled by job listings site CareerCast and spotted by GOBankingRates.com.

CareerCast recently released its lists of the 10 most lucrative jobs in America in 2017, and the 10 lowest paying ones. Education level was the main divider between these two categories, with seven of the top 10 being medical specialties (careers that require years of extra schooling) and five of the lowest being in the service industry.

In all, surgeons make the most money, taking home an annual median salary of nearly $410,000. The next two decades are expected to be fruitful ones for this medical specialty, with a projected growth outlook of 17 percent.

Ranking just behind surgeon are orthodontists, with a $208,000 annual median salary; psychiatrists, who make $194,740; and general practice physicians, who make $190,490. That said, you don’t need to become a doctor (or even go to grad school) to score a high paycheck. Other top jobs include chief executive, with annual median pay of $181,210, petroleum engineers ($128,230), and air traffic controllers ($122,410).

Food servers—who live off both wages and tips—have the lowest paying jobs, according to CareerCast's data. They earn an annual median salary of $19,630 per year. But since this sector is expected to see a growth outlook of 14 percent in the next 20 years, a good server will likely always be able to find work, even if it's not well-paid.

Cashiers, on the other hand, are projected to see negative growth. This dip could be explained by the rise of e-commerce and automated services, among other factors. In addition to vanishing job prospects, cashiers earn $20,180.

Home health aides rank next on CareerCast’s top 10 lowest-paying jobs list. While workers earn an average yearly salary of $21,170, they can also expect increasing job security due to aging Baby Boomers. The industry is expected to see a 40 percent growth outlook between 2014 and 2024, thanks to the nation's senior population.

Other careers mentioned on CareerCast’s lowest-paying job list include bartender ($20,800), dishwasher ($20,800), childcare worker ($21,170), maid ($21,820), retail sales worker ($22,900), recreation worker ($23,870), and janitor ($24,190). See how other professions fared here.

[h/t GOBankingRates]