Implement of distributed algorithms with MapReduce