in 1402 würzburg got a university. it later closed and then reopened in 1582. in 1631 gustavus adolphus of sweden conquered würzburg in the 30-year war. in 1803 the duchy of würzburg became part of bavaria, in 1938 the city had more than 100,000 inhabitants for the first time. in 1945 the city was nearly completely destroyed.