from typing import List
from typing import Tuple
import math


def split_to_ranges(vector_lenght: int, range_count: int) -> List[Tuple[int, int]]:
    """
    Divide single range into rangeCount parts. Each part takes form of [a, b)
    Example: splitIntoRanges(10, 3) => [0, 4), [4, 8), [8, 10)
    """
    part_size = math.ceil(vector_lenght / range_count)

    ranges = []
    index = 0
    for _ in range(range_count):
        if index < vector_lenght:
            r = index, min(index + part_size, vector_lenght)

            ranges.append(r)
            index = r[1]
        else:  # There are more ranges than vector length
            ranges.append((0, 0))

    return ranges