chinese-remainder ( aseq nseq -- x )


Vocabulary
math.algebra

Inputs
aseqa sequence of integers
nseqa sequence of positive integers


Outputs
xan integer


Word description
If nseq integers are pairwise coprimes, x is the smallest positive integer congruent to each element in aseq modulo the corresponding element in nseq.

Definition