Implementations of ModDot, the dot product of two vectors modulo a number, accumulating the sum before reducing it once.
ModDot