By HILARY SPURLING

A. J. AYER

A Life.

By Ben Rogers.

Illustrated. 402 pp. New York:

Grove Press. $30.



ne of the last of the many legendary contests won by the British philosopher A. J. Ayer was his encounter with Mike Tyson in 1987. As related by Ben Rogers in ''A. J. Ayer: A Life,'' Ayer -- small, frail, slight as a sparrow and then 77 years old -- was entertaining a group of models at a New York party when a girl ran in screaming that her friend was being assaulted in a bedroom. The parties involved turned out to be Tyson and Naomi Campbell. ''Do you know who . . . I am?'' Tyson asked in disbelief when Ayer urged him to desist: ''I'm the heavyweight champion of the world.'' ''And I am the former Wykeham professor of logic,'' Ayer answered politely. ''We are both pre-eminent in our field. I suggest that we talk about this like rational men.''

So they did, while Campbell slipped away. There are endless stories like this about Ayer's charm, nerve and dazzling powers of improvisation. He was famous for responding clearly and directly without showing off or talking down, whether it was to a television audience, an overconfident student or a boxing titleholder. He was as competitive as Tyson, partly, no doubt, because he never entirely got over a similar sense of being an outsider. Both needed to assert themselves by proving and re-proving their own worth. Their almost childlike delight in worldly success found its downside in an equally childish arrogance and insensitivity. Each had an insatiable drive to seduce women coupled with frank inability to take them seriously as equal human beings.

Alfred Jules Ayer (1910-89) was the only child of an unsuccessful financier who went bankrupt 18 months after his son was born. His mother was the daughter of a rather more prosperous Jewish businessman who kept the family afloat and paid Freddie's tuition and liberal allowance. Twenty years younger than her husband, Reine Ayer possessed a fine intellect frittered away, according to her son, on an empty life and an unhappy marriage. Freddie was packed off to boarding school at 7. Physically pampered, socially isolated, emotionally neglected, familiar from birth with the stifling atmosphere of adult silence and depression, he grew up restless, resourceful and self-reliant. His lifelong passion for football and films developed early. As a solitary small boy, he taught himself to tap-dance and dreamed of going on the stage or playing cricket for England.

In 1922 he became the youngest scholarship student at Eton. Bright, bumptious and small for his age, he was handed over for five years to the care of a sadistic housemaster, ''Bloody Bill'' Marsden, who disliked any sign of cockiness, cleverness or foreign origins in his charges. Ayer seldom spoke about his Eton schooling. No one encouraged him to read philosophy. It was a taste he discovered for himself, shortly before leaving with another scholarship to read classics at Christ Church College, Oxford. Here, he marked himself as suspect from the start by arriving at 18 already equipped with a mistress: a beautiful, cosmopolitan girl called Renée Lees, whose sophistication stood out like a Martian's in an all-male college where women were still forbidden to dine in hall and most of the other boys had barely so much as spoken to a female contemporary. Christ Church was by far the grandest, most aristocratic and church-minded of all the Oxford colleges, with an even higher than usual proportion of homosexual dons. Ayer was half Jewish, a militant atheist and flamboyantly heterosexual.

On top of which he took as his formative influence Ludwig Wittgenstein's ''Tractatus Logico-Philosophicus.'' Few people at Oxford had heard of, let alone read, this prodigiously impenetrable work (a few years later Ayer would be the first to include Wittgenstein on a lecture syllabus). Ayer wolfed it down without apparent effort. In little more than a year he had learned all he could from Wittgenstein, whose handling of problems no longer interested him: ''I am bold enough to want to attempt that on my own.'' Ayer's enthusiasm for an obscure foreigner operating out of the rival outfit at Cambridge did him no good. In his final examinations he was marked down for a second by the philosophy department, scraping a first-class degree only on the strength of his ancient history papers. From then on Oxford repeatedly snubbed him. He was turned down for the John Locke philosophy prize, passed over for a college job and rejected as a fellow by All Souls. ''Oxford is afraid of him,'' Ayer's friend and contemporary Isaiah Berlin said.

In the end, Christ Church reluctantly granted him a humble academic post initially created for Albert Einstein. Ayer published his first book, ''Language, Truth and Logic,'' in 1936. It brought him a success out of all proportion to its sales of just over 1,000 copies (64 years later, the book still sells 2,000 a year in Britain: a 1945 reprint in the United States has sold 300,000). It was one of those books that galvanize a whole generation. Ambitious undergraduates commonly read it at a sitting. Their elders were appalled. When students tried to discuss the book at an Oxford seminar, the Master of Balliol flung it through the window. Ayer was denounced by a housemaster at Winchester School as the wickedest man in Oxford. Asked what came next, the young iconoclast said cheerfully: ''There's no next. Philosophy has come to an end. Finished.''

Ayer belonged to an empirical, anti-authoritarian generation in vehement revolt against an enfeebled, overblown and contaminated metaphysical tradition. Far from laying down the law, he sought to streamline, modernize and cut back the role of philosophy. He insisted it had no business offering guidance on moral or ethical choices. Logical positivism was to be the scientific and functional equivalent of Bauhaus design in engineering and architecture. It responded to the brutal political realities of the 1930's in ways more conventional thinking could not manage. Wittgenstein, spoken of in some quarters as a second Christ or Pythagoras, was its secular high priest.

Readers were exhilarated by the intellectual boldness, lucidity and vigor of ''Language, Truth and Logic.'' ''Never has philosophy been so fast, so neat,'' Rogers writes. The boy who had taught himself to tap-dance brought to philosophy many of the qualities -- phenomenal agility, discipline, daring and confidence -- that made Fred Astaire a genius. Friends watching Freddie Ayer glide over the dance floor in a soft-shoe shuffle sometimes felt he might at any moment shimmy up the walls and along the ceiling. Ayer's professional peers in the 30's and 40's tended to agree. His future colleague Richard Wollheim mistook him at their first meeting for the dancer and choreographer Frederick Ashton.

After World War II Ayer ran the philosophy department at University College, London, as his power base, eventually acceding to Oxford's Wykeham chair of logic and becoming an elder statesman of the fashionable left. He had three wives (four if you count one of them twice), three children and countless lovers. ''Some men played golf. Freddie played women,'' said Dee Wells, whom he married and remarried as his second and fourth wife. His energy, humor and subtlety made him irresistible in spite of no-go areas (''A woman who talks about my subject is wholly intolerable''). Human emotion baffled Ayer. He had a quizmaster's encyclopedic knowledge of English classic novels, but art, music and nature meant nothing to him. The aridity of his personal relationships is startling in the hands of a biographer who grants women scarcely more individuality than the Siamese cats or seahorses Ayer periodically adopted as pets. His girlfriends are often anonymous (like the seahorses). The feelings and behavior of the women closest to him remain as inscrutable as the ''Tractatus.''

On all other counts this is an admirably sharp, informative and entertaining biography. Argument raged at the time and since about Ayer's philosophical impact. Wittgenstein was scathing (Ayer ''has something to say but is incredibly shallow''). Berlin said that not even Bertrand Russell had written better prose, but that as a practitioner Ayer was more of a mechanic than an inventor: ''He fiddled with things and tried to fix them.'' Rogers, also the author of ''Pascal: In Praise of Vanity,'' suggests that Ayer achieved precisely what he set out to do: to evolve a modern philosophy that would function in the impure area between worldly affairs and the dry, clear, virtually uninhabitable altitudes of abstract thought.

