For most Ukrainians, the fall of President Viktor Yanukovych is as exhilarating as it is dangerous. Much as they may want to celebrate, the country's more urgent challenge is to avoid bankruptcy and civil war.

Averting catastrophe may sound like a modest goal. But it will require restraint and clarity from Ukraine's leaders and international partners alike -- commodities in rare supply during the brief 22 years since this country of 46 million gained its independence in the collapse of the former Soviet Union.

Yanukovych and his security chiefs must answer, assuming they can be caught, for the deaths of the last few weeks. Yet Ukraine's transitional leaders need to avoid any campaign of retribution against pro-Russia Ukrainians in the east. The pro-European protests against Yanukovych, an ally of Russian President Vladimir Putin, gained support across Ukraine because they were directed at corruption and arbitrary rule. That support would vanish in the face of any attempt by one part of the country to declare victory over the other.

Ukraine must also be careful to avoid the mistakes of the 2004 Orange Revolution, after which the country's new leaders pursued an open-ended quest to seize what they considered to be the ill-gotten gains of the old regime. The campaign created uncertainty that discouraged investment and damaged growth, losses that Ukraine cannot now afford.

The danger of letting politics drive economics is especially acute today, because Ukraine is effectively bankrupt. A rescue will require a substantial international bailout, based on the International Monetary Fund's stalled $15 billion loan program. That would mean Ukraine would have to follow through on the painful reductions to energy subsidies and other reforms that the IMF is demanding. In return, the IMF could allow Ukraine to delay these changes until after presidential elections on May 25.

The IMF loan won't be enough on its own. The U.S. and European Union should make it clear to Ukrainians that they are ready to chip in, on the condition that any transitional government is inclusive and follows the rule of law. The EU should, in addition, reopen negotiations to sign the trade and association agreement Yanukovych refused in November, as well as offer Ukraine a clear path to potential membership, something the bloc has until now refused to do.

Finally, although Putin overplayed his hand -- it is now inconceivable that a united Ukraine would opt to join his Eurasian Union, for example -- he continues to hold powerful cards. Russia can still throttle its neighbor's economy by closing the borders to trade, or by raising the price Ukraine pays for natural gas. It can also stir up pro-Russian populations in Crimea and the east, or even send in troops.

The trick is getting Russia to work with European nations in furthering its interests -- which are not necessarily at odds with those of the Western world. There is a deal to be had here that, in truth, has always been on the table: Ukraine will not join the North Atlantic Treaty Organization, which Putin sees as hostile, because a majority of Ukrainians don't want to. Ukraine will, however, slowly integrate further with the EU. Putin should now make it clear he will not stand in the way.

The outlook for this divided country remains extremely uncertain. The removal of Yanukovych, a corrupt and feckless leader, is no small achievement. A far greater, and more difficult, achievement will be rebuilding the politics and economy of a nation whose problems go far beyond one man.

To contact the editor responsible for this article: David Shipley at davidshipley@bloomberg.net.