| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| int a=1,b=2,c=3;
printf("%d,%d",a,b,c);
What is the output?
| Verifone | 14 |
| How to calculate Total working time using Login and
logout? | Wipro | 2 |
| how to copy a string without using c function | | 5 |
| what is the differance between pass by reference and pass
by value. | Infosys | 4 |
| what is the code for getting the output as
*
**
*** | Caritor | 5 |
| Function to find the given number is a power of 2 or not? | Motorola | 12 |
| 44.what is the difference between strcpy() and memcpy()
function?
45.what is output of the following statetment?
46.Printf(“%x”, -1<<4); ?
47.will the program compile?
int i;
scanf(“%d”,i);
printf(“%d”,i);
48.write a string copy function routine?
49.swap two integer variables without using a third
temporary variable?
50.how do you redirect stdout value from a program to a file?
51.write a program that finds the factorial of a number
using recursion? | | 3 |
| main()
{
clrscr();
}
clrscr();
| ME | 3 |
| difference of two no's with out using - operator | | 6 |
| what will happen if you free a pointer twice after
allocating memory dynamically ? | Novell | 2 |
| what is the difference between #include<stdio.h> and
#include "stdio.h" ? | | 2 |
| for(i=1;i>0;i++);
printf("i=%d",i);
what will be the answer???? | | 6 |
| 1.what are local and global variables?
2.what is the scope of static variables?
3.what is the difference between static and global variables?
4.what are volatile variables?
5.what is the use of 'auto' keyword?
6.how do we make a global variable accessible across files?
Explain the extern keyword?
7.what is a function prototype?
8.what does keyword 'extern' mean in a function declaration?
| | 1 |
| write a program structure to find average of given number | | 1 |
| what is use#in c | | 3 |
| which header file contains main() function in c? | TCS | 3 |
| void main()
{int a[5],i,b=16;
for(i=0;i<5;i++)
a[i]=2*i;
f(a,5,b);
for(i=0;i<5;i++)
printf("\n %d",a[i]);
printf("\n %d",b);
}
f(int *x,int n,int y)
{
int i;
for(i=0;i<n;i++)
*(x+i)+=2;
y=y+2;
}wat r the errors in the prg.and improvise the prg to get o/p.? | | 2 |
| We can draw a box in cprogram by using only one printf();&
without using graphic.h header file? | NIIT | 3 |
| how many header file is in C language ? | | 14 |
| what is the function of .h in #include<stdio.h> in c ? | IBM | 9 |
| |
| For more C Interview Questions Click Here |