These are the best and worst cities for boomers, Gen Xers, millennials, and Gen Zers.

Whether you thrive in a city or can’t wait to move from one may have nothing to do with the metropolis itself, but rather the year you were born.

Researchers from TYE Medical crunched the numbers and came up with the “best” (and “worst”) cities in America based on the specific needs of each generation: baby boomers, Generation X, millennials, and Generation Y.

Your generation can determine the best city for you based on your needs

They examined various factors to determine a score for the 50 largest U.S. cities, collecting data from the U.S. Census Bureau and other public sources. Analysts arranged data based on three factors: generation’s local population share, healthcare availability, state’s tax friendliness for retirees, school quality, number of open management-level jobs, media house price, number of open entry-level jobs, and average rent for 1 bedroom/studio apartment units. Based on these factors, they then ranked areas out of a possible “city score” of 25 (we show all city scores below).

Check out the major metropolitan spots below to see which cities could be an excellent fit for you… and which to avoid.

Best cities for baby boomers

Members of this generation—born between 1946 and 1964—are either retired or approaching retirement, so researchers examined data like healthcare availability and each state’s tax friendliness for retirees.

Research reveals Pittsburgh, PA is by far the top city for baby boomers. However, the generation’s local population share and the low number of primary care providers dropped Austin, TX to the bottom of the list.

1. Pittsburgh, PA – 24.5

2. St. Louis, MO – 20.1

3. Providence, RI – 19.8

4. Cleveland, OH – 19.6

5. Cincinnati, OH – 17.4

Worst cities for baby boomers

1. Austin, TX – 5.4

2. San Diego, CA – 6.4

3. San Antonio, TX – 6.8

4. Minneapolis, MN – 7.0

5. Denver, CO – 7.1

Best cities for Generation X

Gen Xers—born between 1965 and 1980—are likely parenting school-aged children and advancing in their profession at this stage in life, so researchers looked at statistics like school quality and the amount of available management-level jobs.

The data shows Atlanta, GA is the best choice for this generation with its high number of top-ranked schools and upper-level career spots available. San Francisco, CA came in at a close second.

1. Atlanta, GA – 22.6

2. San Francisco, CA – 21.6

3. Washington, D.C. – 20.6

4. Raleigh, NC – 18.6

5. Hartford, CT – 18.2

Worst cities for Generation X

1. Oklahoma City, OK – 0.6

2. San Antonio, TX – 2.6

3. Memphis, TN – 3.1

4. New Orleans, LA – 3.2

5. Virginia Beach, VA – 3.9

Best cities for millennials

Researchers looked into median house prices and the number of open entry-level jobs since members of this age group—born between 1981 and 1996—are likely pursuing homeownership and are typically in the early stages of their careers.

The study’s findings suggest the West Coast is the place to be for this generation. In fact, the top 10 best metropolitan areas for Millennials feature more west-coast locations than any other generation.

1. Salt Lake City, UT – 21.4

2. Washington, DC – 20.1

3. Denver, CO – 19.6

4. Seattle, WA – 19.2

5. Boston, MA – 18.9

Worst cities for millennials

1. Louisville, KY – 4.2

2. Memphis, TN – 4.8

3. Buffalo, NY – 4.9

4. Cleveland, OH – 5.3

5. New Orleans, LA/Oklahoma City, OK – 5.7 (Tied)

Best cities for Generation Z

The population of Gen Zers—born between 1997 and 2012—are probably just starting in their careers. They could also be full-time students or working part-time, so researchers considered factors like the availability of part-time jobs and the average rent for one-bedroom/studio apartment units.

Salt Lake City, UT isn’t just for the millennials, it was Number 1 for Gen. Z-ers, too! However, New Orleans, LA is ranked lowest due somewhat to low part-time job availability.

1. Salt Lake City, UT – 20.0

2. Riverside, CA – 18.1

3. Atlanta, GA – 18.0

4. Hartford, CT – 17.5

5. Boston, MA – 17.1

Worst cities for Generation Z

1. New Orleans, LA – 4.8

2. Jacksonville, FL – 5.3

3. Louisville, KY – 5.6

4. Buffalo, NY – 6.7

75. San Jose, CA – 7.4

Did your city make it to one of the lists? Check out this interactive table for the full breakdown of how each metropolitan area stacks up.