get correct end slot from start slot