The school kids in this Chicago suburb are going to get a break the first full week in October. President Carter is coming to town on Oct. 6 and Ronald Reagan arrives just two days later, and both men are counting on the classrooms being emptied to swell their crowds.

The sudden popularity of this DuPage County town is no more accidental than Carter's scheduled visit to Delaware County and Geoege Bush's appearance in Montgomery County -- both Philadelphia suburbs -- on Thursday and Friday of this week.

As the long election campaign enters its final five weeks, the battle for the swing states such as Illinois and Pennlsylvania is increasingly becoming a battle for the suburbs. Pennsylvania's 27 electoral votes were narrowly Democratic in 1976 and Illinois' 26 votes even more narrowly Republican.

Political legend still has it that Carter's fate, like that of earlier Democratic candidates, will be decided by his margin in the big cities such as Philadelphia and Chicago. But his managers know better. "We can lose it [the election] in Chicago," says Joe Novak, the Illinois field director of the Carter-Mondale campaign, "but we can't win it."

Because of declining big-city populations, weakened big-city machines, a certain loss to Reagan of some blue-collar and ethnic votes and a probable loss of some liberal, student and Jewish votes to independent John B. Anderson, Carter realistically cannot hope to match his 1976 margins in Philadelphia or Chicago.

That is forcing the president to compete for votes in the normally Republican "collar counties" around Chicago and Philadelphia -- areas where he is helped by the moderate Republicans' disquiet about some of Reagan's hard-line attitudes and by the great uncertainty about where the Anderson vote is coming from now, and where it will ultimately go.

In both states, there was a strong subjective feel this past week -- supported by a scattering of local polls -- that, despite Anderson's showing in last Sunday's television appearance with Reagan, his campaign is in a tailspin.

With no more "debates" scheduled, no funds for paid TV ads, and local volunteers under orders to put aside voter contact and concentrate on soliciting funds for Anderson's personal campaign travel, much of what was once Anderson's vote appears for now to be swelling the ranks of the undecided.

In a place like DuPage County, where Anderson received about 40,000 votes in the March GOP primary and came within 900 votes of beating Reagan, there is an acute sense in both the Reagan and Carter camps that a big chunk of the vote is still there to be won.

Pate Philip, the staunchly conservative Republican county chairman, estimates that swing vote at "27 to 30 percent" in his county. Bob Asher, the GOP chairman in Montgomery County, west of Philadelphia, says, "The moderate Republican ticket-splitter vote here is very soft. It's definitely not Carter's today, but it's not Reagan's either."

Because of that, the GOP campaigns are putting extra efforts into what are normally viewed as "safe Republican" suburbs. Intensive direct-mail and phone canvasses are backing up personal appearance like those Reagan and Bush are making in the suburban areas of the two states within the next week.

What is different in 1980 is that the Carter campaign is also focusing on the suburbs. "In 1976," said Sue Ellen Johnson, the Carter-Mondale coordinator in a group of "collar counties" including her own DuPage County, "our orders were to keep a low profile. They [the senior strategists] didn't want people here to be reminded there was an election, and we couldn't convince them that they were going to vote, no matter what, and that Carter just had to compete for his share."

The result, as Mike Casey, the Carter state coordinator, and Joe Novak, his field director, point out, was this paradox: In 1976, Carter received more votes (72,137) in DuPage County than in any other in Illinois Except Cook County (Chicago). But in percentage terms, his 29.2 percent in DuPage was 102nd of the 102 counties in Illinois. Ford's plurality in DuPage County alone was 9,000 votes greater than his statewide margin of 92,974 votes.

This year, the Carter strategists in Illinois are giving top priority to reducing the GOP margin in DuPage and other neighboring counties.

"If we can get Carter up to 33 percent and Anderson winds up with 10 percent," said Novak, "that doesn't leave a whole lot for Reagan." Such an outcome would, in fact, cost the Republicans half of Ford's 1976 victory margin.

But winning it will not be easy. Bill O'Donaghue, the young Boston politician who came to Illinois to run DuPage County for Sue Ellen Johnson, has targeted those precincts where the median Democratic vote in 1976 and 1978 was 30 percent -- and the handful of precincts where it topped 40 percent. He is trying to hire phone convassers and recruit volunteers to "work" those precincts, in hopes of expanding the Carter vote.

But it is hard going. DuPage is prosperous, white and Protestant country -- with hardly any blacks, Jews or ethnic blocs on which to build a vote. Illinois House Speaker William A. Redmond, who is also the Democratic county chairman, says, "I don't think I know a Jew in this county." Johnson says, "I had two in my precinct, but they moved back to New York."

The Democratic organization is pitifully weak. Redmond says he is sure there are at least 200,000 unregistered voters in the county, but he seems indifferent or overwhelmed at the thought of trying to register them.

In Montgomery County, Pa., the Democrats are not only weak but faction-ridden. The county chairman, Colleen Alexander, has been trying to spark some Carter effort, while coping with her own late-starting campaign for the legislature and being hobbled by a broken foot.

Still, there are vulnerabilities for Reagan in these suburbs that make it impossible to write off the Carter effort. Reagan was beaten 2 to 1 by Bush in Montgomery County in the April primary, despite the fact that Montgomery is the home base of Drew Lewis, then Reagan's Pennsylvania campaign manager and how his deputy campaign chairman and liaison with the Republican National Committee.

While such moderate Republicans as Pennsylvania Gov. Dict Thornburgh assert that "putting Bush on the ticket has prevented any erosion of moderates like Goldwater suffered in 1964," others are not so sure.

"We constantly push Bush," said county GOP chairman Asher, "because that takes the edge off Anderson." But a state GOP official, very close to the governor's office, said privately he was not sure that Bush alone would overcome the doubts about Reagan. "It would be easier," he said, "if the ticket was reversed."

In Illinois Redmond says, "There are a lot of Republicans here who don't like Reagan's opposition to the 55-mile speed limit, his litmus test [on abortion] for judges, or his stand on ERA. The Republican voters are more moderate than their leaders."

Whether or not those doubters can be lured to Carter's column (or encouraged to vote for Anderson), the president's forces have no alternative but to try their luck in the suburbs. He has to make up ground there that he expects to lose elsewhere.

In Illinois, for example, a number of polls have found Carter's strength down in southern Illinois' coal fields, where he ran well in 1976. In Pennsylvania, he is hurting in the normally Democratic hard-coal country of Scranton and Wilkes-Barre.

But the main problem in both states is that Carter is unlikely to duplicate his 1976 margins in the big cities of Philadelphia and Chicago.

Both cities have elected new mayors since 1976 -- Bill Green in Philadelphia and Jane Byrne in Chicago -- and both did their best to knock off Carter in the primaries. Byrne failed to deliver the organization vote to Sen. Edward M. Kennedy, but Green carried 68 of his 69 wards for the challenger.

Since the convention, the White House has been busy making amends to both mayors and their machines. After further aggravating Green by opposing his election as chairman of the Pennsylvania delegation, the Carter administration has reversed decisions that would have removed a Defense Supply Agency installation from Philadelphia, closed down a drug-enforcement unit and denied urban-development grants.

The olive branch is also out to Mayor Byrne, who has been invited to two White House functions in the past 10 days and has been given major airport and transportation grants to announce.

In an interview in her office before her most recent trip to Washington, the mayor joked, "Diamonds are a girl's best friend, and federal grants are a close second."

But such goodies can purchase only so much help. "Last time," Mayor Green said, "Carter carried Philadelphia by 255,000 votes. This time, it will be in the 175,000-200,000 range."

Dave Glancey, the city Democratic chairman, said the Carter margin might drop as low as 100,000 votes, because "the enthusiasm level is not very high. In 1976, we registered 181,000 people between the April primary and the October cutoff.As of last week, we had only 35,000 new registrants."

Although neither Green nor Glancey would discuss it on the record, the turnout problem goes far beyond Carter. Pennsylvania Democratic senatorial candidate Pete Flaherty, a former Pittsburgh mayor, is popular in western Pennsylvania and will help Carter. But he is a weak candidate in Philadelphia against former Philadelphia district attorney Arlen Specter, a Republican.

And more than a half-dozen local Democratic candidates and officials -- congressmen, city council members, ward committeemen -- have been convicted, or are facing trial on charges of financial irregularity.

"You can imagine," said one untainted city Democrat, "what that does to your organization morale."

In Chicago, the current scandals are relatively mild but the machine is wracked by a continuing civil war between Byrne and Richard M. Daley, the son of the late mayor, and now the candidate for the key job of Cook County state's attorney.

The Carter forces have allied themselves with Daley, but his brother Bill Daley, the strategist in this generation, says that despite recent encouraging private polls, "it will be very difficult for Carter to get his 1976 margin [425,000] in Chicago this year, unles they can get Reagan to make some more blunders. Reagan is doing well on the northwest and southwest sides [both Catholic, ethnic areas]. They like Reagan because they're tired of government moving into everything. They think government is worried about foreigners and minorities and doesn't care about them."

Byrne, offering a similar analysis, adds that "if the antagonism [between herself and Daley] persists, it is going to hurt Carter. Committeemen in Chicago don't care that much about a president; they care about things at home. If they feel insulted by Richie Daley, they'll just wash their hands of it, and that will hurt the president."

With "supporters" like that, it is not surprising that Carter has decided to take his chances in the suburbs.