Answered step by step
Verified Expert Solution
Question
1 Approved Answer
This body of code works fine. I am trying to make some change to make it more efficient. Don't worry about what is misssing. It's
This body of code works fine. I am trying to make some change to make it more efficient.
Don't worry about what is misssing. It's the C.
Make any modification as you please, except don't change any name Like the functions and variables.
When take the factorial of 2000 it takes 55 msec. I want it to take less than that.
static void calcfactorial(unsigned int n) { unsigned int carry, i, j; len = factorial[0] = 1; for (i = 1;i0; i--) printf("%ld", factorial[i-1]); printf(" "); }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started