The creation of Pakistan in 1947 as its eastern neighbor created problems. In 1973, political crises led to the overthrow of the king. The country's new leader ended the monarchy and made Afghanistan a republic. In 1978, a Communist political party supported by the Soviet Union seized control of Afghanistan's government. This move sparked rebellions throughout the country. The government asked the Soviet Union for military assistance. The Soviets took advantage of the situation and invaded Afghanistan in December 1979.