[Updated] Goldman Sachs Aptitude Test Questions and Answers
Practice List of TCS Digital Coding Questions !!!
Take 50+ FREE!! Online Data Interpretation Mock test to crack any Exams.

C Programming :: Loop Control - Discussion

Home > C Programming > Loop Control > MCQs Questions Discussion

53 / 61

Consider the following iterative implementation to find the factorial of a number.

int main()
{
int n = 6, i;
int fact = 1;
for(i=1;i<=n;i++)
_________;
printf("%d",fact);
return 0;
}
Which of the following lines should be inserted to complete the above code?

Afact = fact + i

Bfact = fact * i

Ci = i * fact

Di = i + fact

Answer: Option (Login/Signup)

Show Explanation

Asked In :: Capgemini

Post Your Answer Here:     

No Discussion on this question yet!