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

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

Answer / sachin patil

44. strcpy copy the string while memcpy copy the memory
contains of locations.

46.fffffff0

49. int a = 5;
int b = 10;
a = a+b;
b = a-b;
a = a-b;

Is This Answer Correct ?    2 Yes 0 No

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

Answer / jessu srikanth

51.factorial of a number using recursion

long factorial(long n){
return (n==0 || n==1)?1:n*n-1;
}

Is This Answer Correct ?    0 Yes 2 No

Post New Answer

More C Interview Questions

What is floating point constants?

0 Answers  


What are the differences between Structures and Arrays?

0 Answers   TCS,


can anyone please tell me wat is backlogs... i was looking for the job openings where i read this.. eligibility criteria minimum 70% in degree without backlogs. is that arrear.. if so is it standing arrear or history of arrears... please help me...

11 Answers   CTS, Indian Navy, L&T, Microsoft, SSB, TCE, TCS,


How can you access memory located at a certain address?

0 Answers  


write a “Hello World” program in “c” without using a semicolon?

9 Answers   CTS, TCS, Wipro,






what is data structure.in linear and non linear data structures which one is better?Explain

3 Answers   Wipro,


what is meant by the "equivalence of pointers and arrays" in C?

3 Answers   Satyam,


1. Write the function int countchtr(char string[ ], int ch); which returns the number of times the character ch appears in the string. Example, the call countchtr(“She lives in NEWYORK”, ‘e’) would return 3.

4 Answers  


is c language is a object oreinted language?

5 Answers   TCS,


How many header files are in c?

0 Answers  


Find the O/p of the following 1) #include int main() { char c='1'; int j=atoi(c); }

4 Answers   Subex,


#include <stdio.h> void main() { int i=-1,j=1,k,l; k=!i&&j; l=!i||j; printf ("%d%d",k,l) ; }

3 Answers   SRG,


Categories