topcoder greedy