| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| find a number whether it is even or odd without using any
control structures and relational operators? | Microsoft | 14 |
| What is difference between the following 2 lines….
int temp = (int)(0x00);
int temp = (0x00int);
| Bosch | 3 |
| #ifdef TRUE
int I=0;
#endif
main()
{
int j=0;
printf("%d %d\n",i,j);
}
| ADITI | 2 |
| What's the difference between calloc() and malloc()? | | 3 |
| How to receive strings with spaces in scanf() | | 4 |
| what is difference between array and structure?
| TCS | 19 |
| can you explain in brief what is "r+" mode in a file... i
know that it si used to read and modify rhe existing
content.... but explalanation about the file pointer in "r+"
mode i wann to know??????????? | Cognizent | 1 |
| void main()
{
int s[4][2]={ {1234,56},{1212,33},{1434,80},{1312,78} };
int (*p)[2];
int i,j,*pint;
for(i=0;i<=3;i++)
{
p=&s[i];
pint=p;
printf("\n");
for(j=0;j<=1;j++)
printf("%d",*(pint+j));
}
} while running this program it shows a warning-suspicious
pointer conversion ie pint=p; my que is why should we assign
the value of p to pint again.why cant we use it directly as
*(p+j)..but if i use like tat the o/p is garbage value.. | | 1 |
| sir,
i cannot find the way how to write aprogram by using
array on queue | IISIT | 1 |
| what is meant by the "equivalence of pointers and arrays" in
C? | Satyam | 3 |
| f(char *p)
{
p=(char *)malloc(sizeof(6));
strcpy(p,"HELLO");
}
main()
{
char *p="BYE";
f(p)
printf("%s",p);
}
what is the output?
| Hughes | 6 |
| find second largest element in array w/o using sorting
techniques? use onle one for loop. | Zycus-Infotech | 2 |
| what is the output for the code :
main()
{
int i,j;
printf("%d %d ",scanf("%d%d",&i,&j));
} | Infosys | 15 |
| what are the difference between ANSI C and Let Us c and Turbo C | LG-Soft | 1 |
| What is the diffrent between while and do while statement ? | | 5 |
| Which is not valid in C?
1) class aClass{public:int x;}
2) /* A comment */
3) char x=12;
| | 5 |
| Why cann't whole array can be passed to function as value. | | 1 |
| write a program to generate 1st n fibonacci prime number | | 1 |
| What's a "sequence point"? | | 2 |
| I have a function which accepts, and is supposed to
initialize,a pointer, but the pointer in the caller remains
unchanged. | | 1 |
| |
| For more C Interview Questions Click Here |