In Kiev, hundreds of thousands of Ukrainians have taken to the streets to demand the government join the European Union, in the hopes it will spur economic growth. In Kabul, Afghan leaders overwhelmingly voted to have American troops remain for another decade, in the hopes they will maintain a “war and aid economy” that has brought them unprecedented riches.

As a fiscally constrained and war-weary Washington confronts its foreign policy challenges, events in Ukraine and Afghanistan show that economic incentives can play a major role in addressing them. Younger generations in both countries are eager for prosperity, reduced corruption and a place in a globalized economy. Globalism is challenging cronyism.

In Ukraine, many motives are driving the young demonstrators, who have been protesting since President Viktor Yanukovich abruptly announced that he would not sign an association agreement with the European Union. But a key belief voiced by protesters is that adopting EU-mandated judicial reforms would reduce the country’s staggering levels of corruption.

“They get access to the European rule of law,” Steven Pifer, a Brookings Institution senior fellow and former U.S. ambassador to Ukraine, said in a telephone interview Tuesday. “They don’t have worry about the corruption and the arbitrary seizure of property.”

Many Ukrainians, however, may overestimate the economic benefits of joining the European Union, as Julia Ioffe pointed out in the New Republic on Tuesday. Croatia’s economy, for example, has been tepid since it joined. And one of the first reforms the EU requires would mean increasing the low price of gas set by Ukraine’s notoriously corrupt energy sector.