William B. Miles Jr., 27, a computer analyst and doctoral candidate in computer sciences at the University of Maryland, died of melanoma Tuesday at the National Institutes of Health.

He attended St. Mary's College of Maryland where he won the John I. Dawkins Honor, an award given to the school's most promising student in mathematics.

He later transferred to George Washington University where he earned a bachelor's degree in mathematics. He then earned a master's degree in computer sciences from Johns Hopkins University and was currently working on a doctorate in computer sciences at the University of Maryland.

He also had worked for the government, including an assignment with the Navy that took him to computer projects in Spain, Portugal, the Netherlands, England and Norway.

Mr. Miles, or "Buck" as he was known to friends, wa fluent in French, Spanish and Russian.

His last job was as a computer analyst with the Census Bureau.

He played intramural basketball at both colleges he attended and had belonged to the chess club at George Washington University where he won a tournament. During his final stay at the National Institutes of Health, he continued to play as many games as possible with fellow patients and staff.

He was a member of St. Timothy Hpisonpal Church in Washington.

He is survived by his parents, William B. Sr. and Imogene J., both of the home in Suitland, and his grandmother, Gladys V. Johnson, of Raleigh, N.C.

The family suggests that expressions of sympathy may be in the form of contributions to the American Cancer Society.