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?




Answers were Sorted based on User's Feedback



44.what is the difference between strcpy() and memcpy() function? 45.what is output of the followi..

Answer / vidya v

49.#include<stdio.h>
main()
{
int a,b;
scanf("%d%d",&a,&b);
a=a+b;
b=a-b;
a=a-b;
printf("%d%d",a,b);
}

Is This Answer Correct ?    10 Yes 0 No

44.what is the difference between strcpy() and memcpy() function? 45.what is output of the followi..

Answer / siyaoberoi

46. m getting the result FFF0..
plz correct me if m wrong..

Is This Answer Correct ?    2 Yes 1 No

44.what is the difference between strcpy() and memcpy() function? 45.what is output of the followi..

Answer / swastisundar bose

46.
0000000000000001
47.The progrm will compile,because it is syntactically
correct.
51.
#include<stdio.h>
int fact(int n){
if(n==0||n==1)
return(1);
else
return(n*fact(n-1));
}
void main(){
int a,b;
printf("Enter number:-");
scanf("%d",&a);
b=fact(a);
printf("\nThe factorial value of the number:- %d",b);
}

Is This Answer Correct ?    2 Yes 2 No




44.what is the difference between strcpy() and memcpy() function? 45.what is output of the followi..

Answer / supriya

46. fffffff0
49.#include<stdio.h>
main()
{
int a,b;
scanf("%d%d",&a,&b);
a=a^b;
b=a^b;
a=a^b;
printf("%d%d",a,b);
}
48.
void strcpy(char *s, char *t)
{
while (*s++ = *t++)
;
}

Is This Answer Correct ?    0 Yes 0 No

44.what is the difference between strcpy() and memcpy() function? 45.what is output of the followi..

Answer / 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

44.what is the difference between strcpy() and memcpy() function? 45.what is output of the followi..

Answer / siyaoberoi

44. strcpy() copies only string.it doesnt copy the memory
location.memcpy() copies the memory location of the string.

Is This Answer Correct ?    0 Yes 2 No

Post New Answer



More C Interview Questions

Linked list is a Linear or non linear explain if linear how it working as a non linear data structures

0 Answers  


what are the stages of compilation

1 Answers   Bosch,


How will you write a code for accessing the length of an array without assigning it to another variable?

0 Answers  


Write a C/C++ program to add a user to MySQL. The user should be permitted to only "INSERT" into the given database

2 Answers   Unisys, TCS, Webyog,


How would you sort a linked list?

1 Answers  






how c source file in converted to exe file

5 Answers   KPIT,


What are the average number of comparisons required to sort 3 elements?

2 Answers   DRDO,


Explain what is the difference between far and near ?

0 Answers  


Is main() function predfined or userdefined?

11 Answers  


#include<stdio.h> main() { int i=5; printf("%d",i*i-- - --i*i*i++ + ++i); } tell the answer with correct reason .specially reason is important nt answer ans by turbo c is -39

1 Answers   GameLoft,


In the DOS enveronment, normal RAM that resides beyond the 1mb mark. a) expanded memory b) swapped memory c) Extended memory d) none

0 Answers  


What should not contain a header file?

2 Answers  






Categories