more algorithm work