def solution(integers):
    """
    Finds the two entries that sum to 2020 and returns their product.
    Raises `ValueError` if there is no solution.
    """
    inverse = set()

    for n in integers:
        if 2020 - n in inverse:
            return n * (2020 - n)
        inverse.add(n)

    raise ValueError('no solution found')