def is_even_mod(n, p):
    """
    check if number n mod p is even
    :param n:
    :param p:
    :return: return True if n mod p is even
    """
    if (n % p) % 2 == 0:
        return True
    else:
        return False