def __init__(self, N=(10 ** 9), n=(10 ** 6), mod=((10 ** 9) + 7)):
    self.mod = mod
    self.make_mod_tables(N, n)
def __init__(self, N=(10 ** 9), n=(10 ** 6), mod=((10 ** 9) + 7)):
    self.mod = mod
    self.make_mod_tables(N, n)