I have an equation in the form of n!/c where c is a constant.
I want to find n!/c mod m but I can't seem to get the right value. I tried multiplying n! manually applying mod m at each step but then it doesn't seem to work when dividing it by c mod m, etc.
Mainly, n!/c doesn't compute directly because n! is so large, but then trying to slice down n! as I calculate it renders it incompatible with my c term. Not sure what to do here.