correct errors in FULLY_ADP random select function. but it still has bugs.