| Other C Code Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| why java is platform independent? | Wipro | 10 |
| How do you sort a Linked List (singly connected) in O(n)
please mail to pawan.10k@gmail.com if u can find an
anser...i m desperate to knw... | Oracle | 3 |
| main()
{
int i;
float *pf;
pf = (float *)&i;
*pf = 100.00;
printf("\n %d", i);
}
a. Runtime error.
b. 100
c. Some Integer not 100
d. None of the above | HCL | 1 |
| main()
{
char name[10],s[12];
scanf(" \"%[^\"]\"",s);
}
How scanf will execute? | | 1 |
| main()
{
int i=10;
void pascal f(int,int,int);
f(i++,i++,i++);
printf(" %d",i);
}
void pascal f(integer :i,integer:j,integer :k)
{
write(i,j,k);
} | | 1 |
| main()
{
int x=5;
clrscr();
for(;x==0;x--) {
printf("x=%d\n”", x--);
}
}
a. 4, 3, 2, 1, 0
b. 1, 2, 3, 4, 5
c. 0, 1, 2, 3, 4
d. none of the above | HCL | 1 |
| main()
{
int i =0;j=0;
if(i && j++)
printf("%d..%d",i++,j);
printf("%d..%d,i,j);
} | | 1 |
| What are segment and offset addresses? | Infosys | 1 |
| Given n nodes. Find the number of different structural
binary trees that can be formed using the nodes. | Aricent | 7 |
| You are given any character string. Find the number of sets
of vowels that come in the order of aeiou in the given
string. For eg., let the given string be DIPLOMATIC. The
answer returned must be "The number of sets is 2" and "The
sets are "IO and AI". Vowels that form a singleton set must
be neglected. Try to post the program executable in gcc or
g++ or in java. | | 3 |
| main()
{
int c=- -2;
printf("c=%d",c);
} | | 1 |
| main(){
int a= 0;int b = 20;char x =1;char y =10;
if(a,b,x,y)
printf("hello");
} | | 1 |
| main()
{
extern out;
printf("%d", out);
}
int out=100; | | 1 |
| main()
{
if (!(1&&0))
{
printf("OK I am done.");
}
else
{
printf("OK I am gone.");
}
}
a. OK I am done
b. OK I am gone
c. compile error
d. none of the above | HCL | 1 |
| How to access command-line arguments? | | 4 |
| Is the following code legal?
typedef struct a
{
int x;
aType *b;
}aType | | 1 |
| Finding a number multiplication of 8 with out using
arithmetic operator | NetApp | 8 |
| write a program to count the number the same
(letter/character foreg: 's') in a given sentence. | | 1 |
| #define square(x) x*x
main()
{
int i;
i = 64/square(4);
printf("%d",i);
} | | 1 |
| How will u find whether a linked list has a loop or not? | Microsoft | 6 |
| |
| For more C Code Interview Questions Click Here |