Joseph A. Cannon is leaving the Environmental Protection Agency after four years, three jobs and a track record that gives new meaning to the word "survivor."

It isn't just that Cannon, head of the agency's air division, is the last remaining member of Anne M. Burford's management team, having survived a purge two years ago that eliminated more than 20 of EPA's top-level officials.

It isn't even that he lasted almost two years before that as the agency's policy director, after succeeding a popular incumbent who was fired for being too protective of the agency's career staff.

No, Cannon's long tenure at EPA may be extraordinary simply because his appointment was so . . . improbable.

"I never had a lick of management experience," said Cannon, who is leaving EPA today to join the Washington office of Pillsbury, Madison & Sutro, a San Francisco law firm. "Well," he amended after a moment of thought, "I was in charge of marketing the inaugural license plates in 1972."

Environmental background, then? No. As a lawyer for Addison and Kurth (Treasury Secretary James A. Baker III's former law firm) before he joined EPA in 1981, Cannon dealt mostly with energy regulatory issues.

Great ambition to serve at the EPA? "I got a call from White House personnel and set up this interview with Anne Gorsuch [Burford]," he said. "Then I went to the National Journal to see where this woman worked. For all I knew, it was the Federal Home Loan Bank Board."

Cannon prefers to think of it as "serendipity," but from all appearances it was political patronage, pure and simple, that got him his job at EPA in the early months of Burford's reign.

From all subsequent accounts, it was hard work and a disarming lack of guile that kept him there. Joe Cannon may be the living proof that, even in Washington, nice guys don't always finish last.

Slightly rotund, unpretentious and unfailingly cheerful, Cannon acts more like a Good Humor man than a buttoned-down lawyer or a fast-track executive who pledges allegiance every day to his management-by-objective chart.

"He's just impossible to dislike," an industry representive once fumed in frustration, after delivering an acrid comment on the latest regulatory decision out of Cannon's office.

Similarly, environmentalists spared Cannon the harsh criticism that was leveled at virtually every other EPA official in the first two years of President Reagan's administration. In "A Season of Spoils," an analysis of Reagan's environmental policy, Natural Resources Defense Council attorney Jonathan Lash wrote that Cannon's "distinction was that he listened and learned."

As a result, when William D. Ruckelshaus came in to run the EPA in May 1983, representatives of industry and environmental groups let it be known that they had no objection to keeping Cannon.

Cannon was named assistant administrator for air and radiation, even though, he recalls, Ruckelshaus "wanted an entire new team and Al [Alvin L. Alm, Ruckelshaus' deputy] wanted a PhD in economics" to run the air office.

For Cannon, who harbors a lawyer's weakness for a good debate, it was another stroke of incredible good fortune.

In the halls of the bureaucracy, there are some who interpret the laws, some who enforce the laws, and some who manage those who interpret and enforce the laws. But Cannon is one of the few who view the law as an exercise in metaphysics.

Take the Clean Air Act, a towering hunk of legislation as intricate in structure as it is monumental in scope. Reduced to the essence, the law is supposed to protect ambient air, loosely defined as the air outside a structure to which persons are exposed.

Clear enough for some, maybe, but not, when you think of it a while, quite airtight.

"What about the tops of buildings?" Cannon asks. "Is that ambient air? What if an office window is opened and air comes in? Is that ambient air?

"And what," he says, his voice rising in excitement at the complexity of the thought, "what about the tip of the Transamerica Pyramid? Now you're really talking about angels dancing on the head of a pin!"

But one man's meditation is another man's omphaloskepsis, which may explain why Cannon's relationship with the forces outside the agency were a bit more ragged after he became head of the air office.

Environmentalists opposed his decision, after years of study and legal maneuvering, not to regulate airborne radiation from nuclear facilities and phosphorous mines. Industry shrieked over his moves to tighten the rules on emissions from tall smokestacks, an issue that has dogged the agency for more than a decade.

Neither side is particularly pleased with Cannon's tentative decision on regulating soot emissions from heavy-duty trucks and buses. The rules are neither stringent enough to suit environmentalists nor flexible enough to satisfy manufacturers.

Cannon is unperturbed. By the time his decisions hit the informal news circuit that follows the agency's every twitch, the thunderbolts have been hurled in his office.

"People think there are just fights between industry and environmentalists, but there are raging debates within the agency," he said. Then he added, with his tiny Mona Lisa smile: "I love those debates. Lawyers take to the Clean Air Act."

As an EPA ex-official, Cannon will have to keep his distance from that debate for the next year, but he expects eventually to handle environmental law issues. "I'd like to stay a part of that community, that fabric," he said.

He doesn't rule out returning to the government some day. "I love Washington. I love a place where you can be involved," he said. "The answers to those questions have an impact on the real world."