Conn. (WTNH) — Connecticut students are in luck, as the Nutmeg state was recently ranked as the third most-educated state in the country.

According to the report, conducted by the personal finance site WalletHub, Connecticut ranked highly among the most educated states in the U.S. based on 18 metrics. These metrics measured key points of a well-educated population, including educational attainment, school quality, and achievement gaps between genders and races.

Connecticut took the No. 1 spot for the least gender gap in educational attainment and second for the average university quality. It also ranked in the top three for the percentage of graduate or professional-degree holders, as well as in the top 10 for percentage of people who hold bachelor’s degrees.

The state is known for its colleges, including Ivy League’s Yale University in New Haven, Wesleyan University, Fairfield University, and University of Connecticut.

Connecticut fell just behind Maryland and Massachusetts. Our neighbor state Massachusetts came in first for both educational attainment and quality of education.

On the other end of the spectrum, West Virginia ranked last as the least-educated state in the U.S. Mississippi, Louisiana, Arkansas, and Alabama also fell among the lowest scores.

See how each state ranked via WalletHub here.