Subtract a counter from another in plain tex
\diff=\countOne
\advance\diff-\countTwo
That would be
\diff=\countOne
\advance\diff-\countTwo
For the case that e-TeX is available (\numexpr
):
\newcount\countOne
\newcount\countTwo
\newcount\diff
\diff=\numexpr\countOne-\countTwo\relax