def gf_mul_ground(f, a, p, K):
 if (not a):
  return []
 else:
  return [((a * b) % p) for b in f]

def gf_mul_ground ( f , a , p , K ) : if ( not a ) : return [ ] else : return [ ( ( a * b ) % p ) for b in f ]
compute f * a where f in gf(p)[x] and a in gf(p) .