What is the output of the following progarm?
#include<stdio.h>
main( )
{
int x,y=10;
x=4;
y=fact(x);
printf(ā%d\nā,y);
}
unsigned int fact(int x)
{
return(x*fact(x-1));
}
A. 24
B. 10
C. 4
D. none
Answer Posted / kalyan chukka
A.24
Is This Answer Correct ? | 4 Yes | 4 No |
Post New Answer View All Answers
How is null defined in c?
What is string constants?
write a program in c language to print your bio-data on the screen by using functions.
What is wrong with this declaration?
What is pointer to pointer in c?
Is it valid to address one element beyond the end of an array?
What is an array in c?
What is the purpose of the following code? Is there any problem with the code? void send(int count, short *to, short *from) { /* count > 0 assumed */ register n = (count + 7) / 8; switch (count % 8) { case 0: do { *to = *from++; case 7: *to = *from++; case 6: *to = *from++; case 5: *to = *from++; case 4: *to = *from++; case 3: *to = *from++; case 2: *to = *from++; case 1: *to = *from++; } while (--n > 0); } }
Are there constructors in c?
Explain Function Pointer?
Create a structure to specify data on students as given below: Roll number, Name, Department, Course, and Year of joining. Assume that there are not more than 450 students in the collage. (a) Write a function to print the names of all students who joined in the last 3 years. (b) Write a function to print the data of a student whose roll numbers are divisible by 4.
In a switch statement, explain what will happen if a break statement is omitted?
What is s in c?
Which header file should you include if you are to develop a function which can accept variable number of arguments?
Explain the use of fflush() function?