For example:
Given a variable $n$, and two expressions $n(n-1)/2$ and $n^2 - 1$. If they have the same parity or under what condition, they are all odd, or all even?
I want a general solution which not only applies to these two but all the expressions all of whoese resulting values are integers, to check if two expressions of the same variable have the same parity.