Search results

  1. aitía

    Factorial case 13 and 16

    This works, thank you for your informative responses!
  2. aitía

    Factorial case 13 and 16

    Hi, I have made changes to my code according to your suggestions. One thing I am wondering is my function needs to return an int because this is how I declare it before the function name but you mentioned using unsigned long which I added as a local variable which means I have different types...
  3. aitía

    Factorial case 13 and 16

    My factorial program does not give me the correct results in cases, for instance 13 should be 6227020800 and my output is 1932053504. I display my C program below, is someone able to help me fix it for these cases? I know the formula for factorial is n × (n - 1). int factorial(int nb) {...
Top