modified sorting slightly
fixed merge conflicts in get_starts