Ah, yes, the beaches are crowded again. Just like old times. After an unprosperous beginning to the season, business is booming along the boardwalks. And the same is true of most of the other summer resorts on their various lakes, rivers and hillsides. It wasn't the weather that turned things around in midsummer for the tourist industry. It was the disappearance of the lines at the gasoline stations.

The lines vanished for reasons over which the United States government has no control. Part of the expljnation is the enlightened behavior of American motorists who, at least well into last month, apparently were holding their mileage down significantly. But the crowds at the beaches make you wonder whether those good intentions are holding up. There is also the Iranian revolution, which has by no means yet run its full course. The chronology of the last spasm is instructive, since it could be repeated at any moment.

After several sporadic interruptions, Iran cut off oil exports altogether on the day after Christmas. It takes Iranian oil nearly two months to make the slow ocean voyage to the United States, and the impact didn't reach American ports until mid-February. Industry began rapidly drawing down its storcks and, by Aprrl, the federal government and industry agreed that the stocks were getting dangerously low. The government ordered restrictions of the flow to consumers, and the retail market began to feel the effect in May. That's when the gasoline lines first formed.

These long lags have obscured the view of cause and effect. Iran began exporting again in March, haltingly at first but, by April, fairly steadily. That was before American consumers had even begun to feel the 10 week cutoff. But the ocean voyage still took two months and, because Iran's production stayed low, supplies stayed tight.Secretary of Energy James R. Schlesinger spent June in a complicated public quarrel with the industry over how much oil ought to be used to rebuild stocks, and how much ought to be sent alonp to the consumer. By July stocks were up out of the danger zone and things were running more smoothly.

Is that a happy ending? It looks more like a warning of further trouble to come. There are four million more automobiles, buses and trucks on American highways this summer than there were a year ago. Meanwhile American domestic oil production is declining. That is why U.S. oil imports at last year's level aren't enough to give each American driver as much as he was using last year. And that, in turn, is why the sudden surge of weekend and vacation driving this month has uncomfortable implications.

If July's restraint vanishes in August, along with the gasoline lines, the filling stations will begin to run short and the lines will immediately reappear. It is, in a manner of speaking, a very democratic choice. Those people who use as much gasoline as they did last summer are, in effect, voting to bring the gasoline lines back.