| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| what is the output of below pgm?
void main()
{
int i=0;
if(i)
printf("pass");
else
printf("fail");
} | | 3 |
| the number 138 is called well ordered number because the
three digits in the number (1,3,8) increase from left to right
(1<3<8). the number 365 is not well ordered coz 6 is larger
than 5.
write a program that wull find and display all possible
three digit well ordered numbers.
sample:
123,124,125,126,127,128,129,134
,135,136,137,138,139,145,146,147
148
149,156.......789 | | 3 |
| Binary tree traversing | Qualcomm | 1 |
| why you will give me a job in TCS. | TCS | 5 |
| How to convert a binary number to Hexa decimal number??
(Note:Do not convert it into binary and to Hexadecimal) | Subex | 1 |
| What character terminates all strings composed of character
arrays?
1) 0
2) .
3) END
| | 3 |
| what is the difference between. system call and library
function? | CDAC | 2 |
| what is the difference between strcpy() and memcpy() function? | | 1 |
| how we can make 3d venturing graphics on outer interface | Microsoft | 1 |
| Write a program to generate prime factors of a given integer? | | 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 |
| You are given a string which contains some special
characters. You also have set of special characters. You are
given other string (call it as pattern string). Your job is
to write a program to replace each special characters in
given string by pattern string. You are not allowed to
create new resulting string. You need to allocate some new
memory to given existing string but constraint is you can
only allocate memory one time. Allocate memory exactly what
you need not more not less. | Microsoft | 2 |
| which one is highest Priority in c?
a)=,b)+,c)++,d)== | | 3 |
| plz answer.. a program that takes a string e.g. "345" and
returns integer 345 | | 3 |
| Write a program to print this triangle:
*
**
*
****
*
******
*
********
*
**********
Don't use printf statements;use two nested loops instead.
you will have to use braces around the body of the outer
loop if it contains multiple statements. | | 2 |
| Write a program that takes three variables(a,b,c) in as
separate parameters and rotates the values stored so that
value a goes to b,b,to c and c to a | | 3 |
| How does C++ help with the tradeoff of safety vs. usability?
| | 1 |
| without a terminator how can we print a message in a printf
() function. | NIIT | 5 |
| write an algorithm which can find the largest number among
the given list using binary search ...............
this was asked in the interview | Satyam | 2 |
| how memory store byte
| Huawei | 3 |
| |
| For more C Interview Questions Click Here |