Dr. Ba Maw, 85, the first prime minister and former president of Burma, died May 29 in Rangoon.

In 1937, when Great Britain separated Burma from India and established it as a nation in the Commonwealth, Dr. Maw became prime minister.

As a lawyer, he earlier had defended leaders of a rebellion against British rule. He also became head of the Burmese Independent Movement. He remained prime minister for two years.

The Japanese invaded Burma in 1941. Two years later, Burma was declared independent of Britain and Dr. Maw was named president.

He remained in that prison until the end of World War II, when with the defeat of the Japanese, Burma returned to British control.

Dr. Maw then founded the Mahabama Party, which worked for independence from British rule. Burma became independent for a second time in 1948. Although he never again held political office, Dr. Maw remained influential in Burmese politics until recent years.

He had been educated at Cambridge University and Gray's Inn in England, receiving a law degree from the latter. He also held a doctorate from the University of Bordeaux in France.

He is survived by a daughter, Theda Maw Sturtevant, of Chevy Chase; three other daughters and three sons, all in Burma; 12 grandchildren and seven great-grandchildren.