Two elder statesmen traded compliments at the White House last night and then, as is the prerogative of age, the senior of them lectured his host about the dangers of ignoring poorer nations.

Ivory Coast President Fe'lix Houphoue t-Boigny, 77, told President Reagan, 72, during toasts at a state dinner that the world finds itself in the "absurd situation of wasting money on . . . costly weapons" while assistance for developing nations is "pitifully small."

"The situation is aggravated," he said in French, "by the constant threat against security which compels developing nations to have modest, even inadequate resources to fight simultaneously on two fronts, the development front and the security front--the development too often having to be sacrificed for the security."

In his toast, Reagan said, "You chose the high road of political and economic freedom . . . You advocated compromise over confrontation, conciliation over conflict."

Later, over coffee, Reagan called the African leader "very eloquent" but otherwise made no comment about Houphoue t's message.

"He's quite a man. You know he's been president of that country since 1960," Reagan told reporters surrounding him in the Blue Room.

Did it give him any ideas?

"No, because I can't be," said Reagan. "But he's the father of his country; he was its first president."

Even if he could be president for five five-year terms, as his guest has been, Reagan said he wouldn't because "someday I want to read a book again."

He joked that "Oh, heavens no" he hadn't yet decided what he would now propose at the strategic arms reduction talks (START) in Geneva, although the White House indicated there would be an announcement today. He quipped that he would be staying up after midnight working on the U.S.-Soviet nuclear weapons issue and that it wouldn't be the first time, because "every night I go to bed with homework."

Even so, he and Nancy Reagan stayed at the quieter-than-usual White House party longer than many of their guests. Slipping out right after the entertainment by the Chamber Music Society of Lincoln Center were Vice President and Barbara Bush, most of the senior White House staff, Mary Martin, John Raitt and TV talk show host Gary Collins, with his wife, Mary Ann Mobley, a former Miss America. Both Collins and Martin are nominees for daytime Emmy awards.

Staying on until the Reagans left were Tony Award-winner Jessica Tandy and her husband, Hume Cronyn; Helene Arpels of Van Cleef & Arpels; Rep. Robert J. Lagomarsino (R-Calif.) and his wife, Norma.

The evening's menu included Columbia River salmon in aspic; crown roast of lamb and apricot sorbet bombe. There were three wines, but a State Department biography said Houphoue t neither smokes, dances nor drinks, "although in 1978 he sipped champagne to toast an offshore oil find."

Accompanying Houphoue t-Boigy (pronounced ooFWET-bwahn YEE) on his two-week U.S. trip is his wife, Marie-The're se. For last night's party she wore a sequined red gown. Nancy Reagan wore a sequined white gown featuring a blouson top with long full sleeves.

The Ivory Coast president goes to New York next, where former president Richard Nixon will throw a private dinner for him. The last time the African leader came to the United States was in 1973, when Nixon was still in office. Nixon has visited the former French colony, and a Houphoue t aide said last night the two men "share similar views on world problems."

Guest list at last night's dinner: OFFICIAL PARTY FROM THE IVORY COAST

President Felix Houphouet-Boigny and Marie-Therese Houphouet-Boigny

Simeon Ake, minister of foreign affairs, and Mrs. Ake

Ambassador Rene Amany and Mrs. Amany

Abdoulaye Kone, minister of economy and finance

Denis Bra Kanon, minister of agriculture

Guy Nairay, director of cabinet

Georges Ouegnin, chief of protocol

Amara Essy, permanent representative to the United Nations

Gustave O. Kouassi, aide-de-camp to the president

Pierre Vacher, physician to the president

Nicolas Kouakou, aide-de camp to the president OTHER GUESTS

William Aramony, president, United Way of America, and Mrs. Aramony

Helene Arpels of Van Cleef & Arpels, New York

James A. Baker III, White House chief of staff, and Susan Baker

Robert H.B. Baldwin, president, Morgan Stanley and Co. Inc., and Geraldine Baldwin

G. Duncan Bauman, publisher, St. Louis Globe-Democrat, and Nora Bauman

John Block, secretary of agriculture, and Suzanne Block

Grace Boulton, Republican National Committeewoman from Oklahoma, and Donald Boulton

Vice President Bush and Barbara Bush

Otis Carney, author, and Mrs. Carney

Tom and Dorothy Chauncey of Phoenix

George Clark Jr., chairman, New York Republican State Commitee, and Elizabeth Clark

William P. Clark, national security adviser, and Joan Clark

Gary Collins and Mary Ann Mobley, television personalities

Rudolph Corona, resource coordinator for drug and alcohol abuse in the Butler, Pa., area school district, and Marjorie Corona

Hume Cronyn, actor, writer/director, and Jessica Tandy, actress

Walter R. Cunningham, former astronaut, and Lo Cunningham

Carol Curb of Paris

Kenneth W. Dam, deputy secretary of state, and Marcia Dam

Michael K. Deaver, White House deputy chief of staff, and Carolyn Deaver

Vicomte Olivier de Rohan-Chabot of Paris

John Ellis of Phoenix

Simon Frumkin, of the Soviet Jewry Campaign, Los Angeles, and Mrs. Frumkin

Robert W. Galvin, chairman, Motorola Inc., and Mrs. Galvin

W.H. Krome George, chairman, Aluminum Company of America, and Jean George

Robert Goldwater of Scottsdale, Ariz.

Harry V. Jaffa, professor of political philosophy, Claremont McKenna College, and Marjorie Jaffa

Irving Kristol, editor, Public Interest magazine, and Mrs. Kristol

Rep. Robert J. Lagomarsino (R-Calif.) and Norma Lagomarsino

A.C. Lyles, producer, and Martha Lyles

Justice Thurgood Marshall and Cecilia Marshall

Sen. James A. McClure (R-Idaho) and Louise McClure

Sanford N. McDonnell, chairman, McDonnell Douglas Corp., and Priscilla McDonnell

J.C. Hayward, WDVM television, and Clarence V. McKee, attorney, of Washington

Mary Martin

Edwin Meese III, counselor to the president, and Ursula Meese

Fred Merrill, president, Cereal Food Processors of Kansas, and Virginia Merrill

Buck Mickel, president, Daniel International Corp., and Minor Mickel

Anatole Milunas, chairman, Lithuanian American Republican Federation

Shirley Moore, of the White House staff, and Richard Moore

Sister Renee Oliver of the Citizens for Educational Freedom

Thomas J. Neff, president, Spencer Stuart and Associates, New York, and Susan Neff

Mrs. Antenor Patino of New York

George Pereira of New York

John Raitt, singer/actor/director, and Rosemary Raitt

Rep. Charles B. Rangel (D-N.Y.) and Alma Rangel

Nancy V. Rawls, U.S. ambassador to the Ivory Coast

Daniel L. Ritchie, chairman, Westinghouse Broadcasting and Cable Inc.

Selwa Roosevelt, U.S. chief of protocol, and Archibald B. Roosevelt Jr.

Robert Sakowitz, chairman, Sadowitz Inc., Houston

Lesley Stahl, CBS White House correspondent, and Aaron Latham, writer

Stuart Symington, former U.S. senator, and Mrs. Symington

Rep. Gene Taylor (R-Mo.) and Dorothy Taylor

Harry Torczyner, attorney, New York, and Marcelle Torczyner

Jervis Webb, president, Jervis B. Webb Co., and Patricia Webb

Fritz and Dorothy Weisend of Dallas

Frank G. Wisner, acting assistant secretary of state for African affairs, and Christine Wisner

Robert C. Wright, Pennsylvania state representative, and Mrs. Wright

Vincent and Elaine Zepp of Scottsdale, Ariz.