Added back missing <algorithm> include to Task.cc.