import random


def random_int(length: int) -> int:
    """
    Return a pseudo-random integer based on the provided `length`.

        >>> random_int(3)
        114
    """
    if length < 2:
        raise ValueError("length must be greater than or equal to 2")
    range_start = 10 ** (length - 1)
    range_end = (10**length) - 1
    return random.randint(range_start, range_end)