Question: Labs For Functions Factorial Write a non-recursive function that will accept an integer value n and return the factorial of the value (n!). the answer
Labs For Functions
Factorial
Write a non-recursive function that will accept an integer value n and return
the factorial of the value (n!).
the answer is arrow i have no idea what's wrong??

1 #detine CRT SECURE NO WARNINGS Bint factorial(int n) { int output 1; int i; 4 6 7 8 9 10 output = output * i; return output; 12 13 14 15 16 17 18 19 20 21 int main(void) int k 0; printf("Enter any integer to see its factorial value: In ") //scant( "%1d" , k); factorial %d ! is equal to: ", factorial(k)); printf("The
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
