Demand for loans at the nation's major banks turned down sharply in recent weeks after growing substantially in the first three months of the year and probably won't grow at all for the rest of 1980 because of the recession, top officials of Continental Illinois National Bank said today.

"Our loan demand peaked in the week of March 26," according to George R. Baker, executive vice president of the largest seventh largest bank. That was less than two weeks after President Carter announced a new anti-inflation program with sharp constraints on the extension of credit to businesses and consumers.

Part of the president's program included a ceiling of between 6 percent and 9 percent on the growth of bank loans in 1980. "In mid-March that may have looked troublesome. Now it doesn't look like a problem," said Baker.

He said that because of falling loan demand on the part of both businesses and consumers, interest rates should continue to decline.

The prime rate, which was cut to 16 percent Monday, should be down to 12 percent or 13 percent by the end of the year, he said. Less than five weeks ago, the prime rate was a record 20 percent.

Richard S. Peterson, the bank's chief economist, said that the recession has spread from the housing and automobile industries, to nearly every sector of the economy.

The Commerce Department today revised downward its estimate of economic growth during the first three months of 1980. The department said that gross national product -- the value of goods and services produced by Americans, grew at an annual rate of only 0.6 percent during the first quarter, well below its preliminary estimate of 1.1 percent.

Peterson said that output will decline at an annual rate of about 5 percent during the current quarter and at a somewhat slower rate for the rest of the year, with a recovery beginnig in early 1981.

He said the recession won't be as bad as the one in 1974 and 1975 because businesses don't have the huge excess inventories they had during the mid-1970s slowdown.

By the time the recession ends, the real output of the United States will have fallen about 2.5 percent he said. During the 1974-75 recession, output declined 5.7 percent, the biggest economic slump since the Great Depression.

By the end of March, the value of loans outstanding at Continental and most other major banks was about 6 percent to 7 percent higher than at the end of 1979, Baker said.Since then, because of the slumping economy, loans have fallen so fast that today Continental's loans are at about the same levels they were on Dec. 31. Baker said he doesn't expect loan levels to be any higher at the end of the year than they are today.

"This is true of most major banks around the country," he added.

Although many businesses sharply boosted their lines of credit with banks in anticipation of the March 4 credit restraint program, most of those limes "likely will not be used," Baker said.

Because of the decline in loan demand and interest rates, the Federal Reserve has begun to dismantle some of the credit restraints put in place on March 14.

Baker said that demand for loans probably had peaked by the time the Fed program went into effect, although the program had a psychological impact that "choked off even further" credit demands. If the central bank were to remove the entire program today, it "won't make any difference," Baker said.

In the international arena, the biggest problem areas appear to be Brazil and South Korea, Baker said.