Better tasks sorting