Factorial problem

why am i getting two cases wrong
link is https://ide.codingblocks.com/s/225223

@mayank10
for test case like 81624065 46668091
u are getting 240 answer will be 239

where is the mistake in my code