Danny Simon, 86, a television comedy writer who was obscured by the success of his younger brother, Neil, and who almost was the author of "The Odd Couple," died July 26 at the Robison Jewish Health Center in Portland, Ore., near his home. He had had a stroke.

Mr. Simon initially wrote for radio shows with his brother. While in their teens, they pleased radio humorist Goodman Ace with a line about a witless movie usher explaining a film plot: "Joan Crawford's boyfriend is sent to the electric chair -- and she promises to wait for him."

Their rapid-fire absurdity won them work in the early days of television. The Simons wrote for Milton Berle, Jackie Gleason, Red Buttons, Phil Silvers and, most memorably, for Sid Caesar on "Your Show of Shows," which Neil Simon fictionalized in his Broadway comedy "Laughter on the 23rd Floor" (1993).

One of their colleagues, Woody Allen, spoke admiringly of Mr. Simon, telling an interviewer: "I've learned a few things on my own and modified a few things he taught me, but everything, unequivocally, that I learned about comedy writing, I learned from Danny Simon."

Mr. Simon continued writing scripts and eventually directed TV shows, and Neil Simon fled to the theater to seek his own voice. He used his older brother as inspiration for various characters, including the ladies' man in "Come Blow Your Horn" (1961), the Hollywood producer in "Plaza Suite" (1968) and the older brother in "Brighton Beach Memoirs" (1983), a comic look at their unhappy, fatherless childhood in Brooklyn.

"There have been more plays written about me than about Abraham Lincoln, Joan of Arc and Julius Caesar all put together," Mr. Simon said.

Many of Neil Simon's depictions of his older brother were less than flattering. The younger Simon once told Time magazine, "My complicated relationship with Danny stems from the fact that when I was growing up, I saw him as my father. It wasn't until much later that I saw him as a brother. He'd tell me when to go to bed, how to behave, give me all the rules of life."

Neil Simon's enduring play "The Odd Couple" (1965) was born out of his brother's divorce. Mr. Simon had moved in with a newly single theatrical agent named Roy Gerber in Hollywood, and they invited friends over one night. Mr. Simon botched the pot roast.

The next day, Gerber told him: "Sweetheart, that was a lovely dinner last night. What are we going to have tonight?"

Mr. Simon replied: "What do you mean, cook you dinner? You never take me out to dinner. You never bring me flowers."

The banter left Mr. Simon thinking there was a kernel for a play, and he typed out 14 pages, which he showed to an approving Neil. But he disliked the solitude of playwriting and, despite encouragement from his brother to finish, he returned to collaborative television writing. Neil Simon took over the play, which became a popular stage show that was succeeded by film and television versions.

Although Mr. Simon received a slice of the royalties, he was left out of the acknowledgments, which rankled him and caused a decade-long rift. He suffered in his younger brother's shadow and, when asked how it felt to be Neil Simon's brother, usually replied: "Well, it's better than being Neil Simon's sister."

Mr. Simon wrote one play, "The Convertible Girl," a comedy about a Jewish man who woos a Catholic girlfriend. It never made Broadway but played often at Jewish community centers.

"By Neil's standards of success, I'm a nothing," he once told People magazine. "I've always been trying to prove something to people. I should have gone further with the talent I have."

Daniel Simon was born Dec. 18, 1918, in the Bronx, N.Y. Eight years later came Neil, whom he nicknamed "Doc" after Mr. Simon saw him playing with a toy stethoscope.

Their "playboy" father abandoned the family, Mr. Simon later said. "Sometimes he'd lose jobs because he was out chasing women. Even when he had money, he'd withhold it from us. Neil and I lived in that kind of blackness."

Constant joking with his younger brother helped guard against the painful absence of their father. Much of the sibling rivalry stemmed from bids for their mother's attention, Neil Simon later said.

At 19, Mr. Simon was working as an assistant buyer at Abraham and Straus department store in Brooklyn and was asked to be part of the annual employee show. He said he flubbed his lines so much that he took to ad-libbing. The angry producer told him to do his own skit.

He went home and tried out some lines on his brother. "Neil would sit there doing his homework," he told a reporter years later. "And I'd say, 'Be my sounding board, just sit there and talk to me.' And he would come up with these funny lines, just like he always had. I didn't teach him to be funny. God gave him that."

After his brother left to write plays, Mr. Simon became head writer on "The Danny Thomas Show" and contributed to "The Carol Burnett Show," "Diff'rent Strokes" and "The Facts of Life." He also wrote jokes for Alan King, Mac Davis and Joan Rivers.

In retirement, Mr. Simon lectured about comedy writing. He disliked teaching comedy as if it were a primer in the theories of Aristotle, saying, "Aristotle hasn't written anything funny in years." He told students to watch John Cleese's comedy show "Fawlty Towers" because, as he liked to point out, the angry humor stemmed from character.

His marriage to Arlene Friedman Simon ended in divorce.

Besides his brother, of New York, survivors include two children, Michael Simon of Portland and Valerie Simon of Sherman Oaks, Calif.; and two grandchildren.

Danny Simon, left, felt overshadowed by brother Neil. "By Neil's standards of success, I'm a nothing," he said.