In 1976, Ahmadinejad took Iran's national university entrance examination. According to his autobiography, he was ranked 132nd out of 400,000 participants that year, and soon enrolled in the Iran University of Science and Technology (IUST), located at Tehran, as an undergraduate student of civil engineering. He would later earn his doctorate in 1997 in transportation engineering and planning from Iran University of Science and Technology as well, when he was the mayor of Ardabil Province, located at the north-west of the country.