44.what is the difference between strcpy() and memcpy()
function?
45.what is output of the following statetment?
46.Printf(“%x”, -1<<4); ?
47.will the program compile?
int i;
scanf(“%d”,i);
printf(“%d”,i);
48.write a string copy function routine?
49.swap two integer variables without using a third
temporary variable?
50.how do you redirect stdout value from a program to a file?
51.write a program that finds the factorial of a number
using recursion?
Answer Posted / jessu srikanth
sorry... I made a mistake in the previous 51.answer
i am very sorry...
the solution for recursion is...
long factorial(long n){
return (n==0 || n==1)?1:n * factorial(n-1);
}
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Explain what is the difference between functions abs() and fabs()?
"%u" unsigned integer print the a) address of variable b) value of variable c) name of a variable d) none of the above
What is the difference between malloc() and calloc() function in c language?
Why is sizeof () an operator and not a function?
#define PRINT(int) printf("int = %d ",int) main() {< BR> intx,y,z; x=03;y=02;z=01; PRINT(x^x); z<<=3;PRINT(x); y>>=3;PRINT(y); }
What is data structure in c programming?
main() { inta=10,b=20; a>=5?b=100:b=200; printf("%d ",b); }
Where define directive used?
What is the use of parallelize in spark?
Write a program in c to replace any vowel in a string with z?
How can I get the current date or time of day in a c program?
List at least 10 sorting methods indicating their average case complexity, worst case complexity and best case complexity.
Why do we use int main instead of void main in c?
I was asked to write a program in c which when executed displays how many no.of clients are connected to the server.
How can you allocate arrays or structures bigger than 64K?