| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| How can I return multiple values from a function? | | 3 |
| 52.write a “Hello World” program in “c” without using a
semicolon?
53.Give a method to count the number of ones in a 32 bit number?
54.write a program that print itself even if the source file
is deleted?
55.Given an unsigned integer, find if the number is power of 2? | | 3 |
| write a program to find the sum of the array elements in c
language? | | 3 |
| what is object oriental programing? | | 1 |
| what is compiler | | 5 |
| What is macro? | IBM | 3 |
| what is volatile in c language? | TCS | 1 |
| What are advantages and disadvantages of recursive
calling ? | HP | 6 |
| what's the o/p
int main(int n, char *argv[])
{
char *s= *++argv;
puts(s);
exit(0);
}
| Motorola | 1 |
| how to find the kth smallest element in the given list of
array elemnts.
| Silicon | 3 |
| How can I find out how much memory is available? | Persistent | 1 |
| Print all numbers which has a certain digit in a certain
position
eg:
number=45687
1 number=4
2 number=5
etc | | 2 |
| f1()
{
f(3);}
f(int t)
{
switch(t);
{
case 2: c=3;
case 3: c=4;
case 4: c=5;
case 5: c=6;
default: c=0;}
value of c?
| Geometric-Software | 5 |
| Read N characters in to an array . Use functions to do all
problems and pass the address of array to function.
1. Print only the alphabets . If in upper case print in
lower case vice versa. | | 1 |
| To what value are pointers initialized?
1) NULL
2) Newly allocated memory
3) No action is taken by the compiler to initialize
pointers.
| | 2 |
| What is structure padding ? | HP | 1 |
| What is the main differences between C and Embedded C? | | 1 |
| f(x,y,z)
{
y = y+1;
z = z+x;
}
main()
{
int a,b;
a = 2
b = 2;
f(a+b,a,a);
print a;
}
what is the value of 'a' printed | | 4 |
| Which of the following is not a valid declaration for main
()?
1) int main()
2) int main(int argc, char *argv[])
3) They both work
| | 2 |
| write a C program to print the program itself ?! | TCS | 7 |
| |
| For more C Interview Questions Click Here |