(Note to boss: Maybe we should have a columnist based in Costa Rica?)

What sets Costa Rica apart is its remarkable decision in 1949 to dissolve its armed forces and invest instead in education. Increased schooling created a more stable society, less prone to the conflicts that have raged elsewhere in Central America. Education also boosted the economy, enabling the country to become a major exporter of computer chips and improving English-language skills so as to attract American eco-tourists.

I’m not antimilitary. But the evidence is strong that education is often a far better investment than artillery.

In Costa Rica, rising education levels also fostered impressive gender equality so that it ranks higher than the United States in the World Economic Forum gender gap index. This allows Costa Rica to use its female population more productively than is true in most of the region. Likewise, education nurtured improvements in health care, with life expectancy now about the same as in the United States  a bit longer in some data sets, a bit shorter in others.

Rising education levels also led the country to preserve its lush environment as an economic asset. Costa Rica is an ecological pioneer, introducing a carbon tax in 1997. The Environmental Performance Index, a collaboration of Yale and Columbia Universities, ranks Costa Rica at No. 5 in the world, the best outside Europe.

This emphasis on the environment hasn’t sabotaged Costa Rica’s economy but has bolstered it. Indeed, Costa Rica is one of the few countries that is seeing migration from the United States: Yankees are moving here to enjoy a low-cost retirement. My hunch is that in 25 years, we’ll see large numbers of English-speaking retirement communities along the Costa Rican coast.

Latin countries generally do well in happiness surveys. Mexico and Colombia rank higher than the United States in self-reported contentment. Perhaps one reason is a cultural emphasis on family and friends, on social capital over financial capital  but then again, Mexicans sometimes slip into the United States, presumably in pursuit of both happiness and assets.

Cross-country comparisons of happiness are controversial and uncertain. But what does seem quite clear is that Costa Rica’s national decision to invest in education rather than arms has paid rich dividends. Maybe the lesson for the United States is that we should devote fewer resources to shoring up foreign armies and more to bolstering schools both at home and abroad.

In the meantime, I encourage you to conduct your own research in Costa Rica, exploring those magnificent beaches or admiring those slothful sloths. It’ll surely make you happy.