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


Please Help Members By Posting Answers For Below Questions

A routine usually part of the operation system that loads a program into memory prior to execution a) linker b) loader c) preprocessor d) compiler

708


How can I use a preprocessorif expression to ?

682


Why does not c have an exponentiation operator?

705


Why cant I open a file by its explicit path?

695


Difference between MAC vs. IP Addressing

728






Under what circumstances does a name clash occur?

791


Differentiate between new and malloc(), delete and free() ?

780


what is event driven software and what is procedural driven software?

2116


An integer that indentifies the position of a data item in a sequence of data items a) value b) number c) index d) all of the above

761


Can a local variable be volatile in c?

665


What are header files why are they important?

688


I came across some code that puts a (void) cast before each call to printf. Why?

805


What does int main () mean?

631


What is the right type to use for boolean values in c?

698


What are run-time errors?

689