The Carnival Corporation wouldn’t have much of a business without help from various branches of the government. The United States Coast Guard keeps the seas safe for Carnival’s cruise ships. Customs officers make it possible for Carnival cruises to travel to other countries. State and local governments have built roads and bridges leading up to the ports where Carnival’s ships dock.

But Carnival’s biggest government benefit of all may be the price it pays for many of those services. Over the last five years, the company has paid total corporate taxes  federal, state, local and foreign  equal to only 1.1 percent of its cumulative $11.3 billion in profits. Thanks to an obscure loophole in the tax code, Carnival can legally avoid most taxes.

It is an extreme case, but it’s hardly the only company that pays far less than the much-quoted federal corporate tax rate of 35 percent. Of the 500 big companies in the well-known Standard & Poor’s stock index, 115 paid a total corporate tax rate  both federal and otherwise  of less than 20 percent over the last five years, according to an analysis of company reports done for The New York Times by Capital IQ, a research firm. Thirty-nine of those companies paid a rate less than 10 percent.

Arguably, the United States now has a corporate tax code that’s the worst of all worlds. The official rate is higher than in almost any other country, which forces companies to devote enormous time and effort to finding loopholes. Yet the government raises less money in corporate taxes than it once did, because of all the loopholes that have been added in recent decades.