| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| What is macro? | IBM | 4 |
| write a program to sort the elements in a given array in c
language | | 2 |
| What is the difference between null pointer and void pointer | CTS | 3 |
| What are the preprocessors? | HP | 6 |
| Who is invented by c? | Infosys | 14 |
| difference between function & structure | Verizon | 5 |
| What is structure packing ? | HP | 1 |
| What is encapsulation? | | 1 |
| how to implement stack work as a queue? | | 2 |
| 4.weight conversion:
Write a program that will read weight in pounds and convert
it into grams.print both the original weight and the
converted value.There are 454 grams in a pound.design and
carry out a test plan for this program.
| Wipro | 1 |
| Write a program to generate prime factors of a given integer? | | 3 |
| what is the output of the following program and explain the
answer
#include<stdio.h>
exp()
{
main(5)
}
main(int a)
{
printf("%d",a);
return;
} | Satyam | 3 |
| code for copying two strings with out strcpy() function. | | 5 |
| write a program in 'c' to find the value of p[i+1]^n.p,i,n
are arguments of a macro and n is a integer | | 1 |
| a memory of 20 bytes is allocated to a string declared as
char *s then the following two statements are executed:
s="Etrance"
l=strlen(s);
what is the value of l ?
a.20
b.8
c.9
d.21
| TCS | 4 |
| i want explaination about the program and its stack reprasetaion
fibbo(int n)
{
if(n==1 or n==0)
return n;
else
return fibbo(n-1)+fibbo(n-2);
}
main()
{
fibbo(6);
}
| | 2 |
| write a program for odd numbers? | | 6 |
| How do I initialize a pointer to a function? | | 2 |
| Which of the following is not an infinite loop ?
a.while(1){
....
}
b.for(;;){
...
}
c.x=0;
do{
/*x unaltered within theloop*/
...
}while(x==0);
d.# define TRUE 0
...
while(TRUE){
....
}
| TCS | 4 |
| which one low Priority in c?
a)=,b)++,c)==,d)+ | | 8 |
| |
| For more C Interview Questions Click Here |