def prod(m, n):
    """Compute the product of consecutive integers in range [m,n] inclusive."""
    if n < m:
        return 0
    elif n == m:
        return n

    result = 1
    for i in range(m, n + 1):
        result *= i
    return result