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 / dhina
#include<stdio.h>
#include<conio.h>
void fact();
void main()
{
clrscr();
fact();
getch();
}
void fact()
{
int n,f;
scanf("%d",&n);
if(n==1)
{
return(1);
}
else
{
f=(n*fact(n-1));
printf("%d",f);
}
}
| Is This Answer Correct ? | 4 Yes | 6 No |
Post New Answer View All Answers
What is the difference between char array and char pointer?
How do I determine whether a character is numeric, alphabetic, and so on?
Explain do array subscripts always start with zero?
Explain enumerated types.
What is the difference between fread and fwrite function?
What is an identifier?
Is sizeof a keyword in c?
What is a stream water?
Explain how can I prevent another program from modifying part of a file that I am modifying?
a way in which a pointer stores the address of a pointer which stores the value of the target value a) reference b) allocation c) multiple indirection d) none
using for loop sum 2 number of any 4 digit number in c language
what is the height of tree if leaf node is at level 3. please explain
What is methods in c?
What is scope rule of function in c?
What is the function of volatile in c language?