| Other C Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| n=7623
{
temp=n/10;
result=temp*10+ result;
n=n/10
}
| Wipro | 3 |
| main()
{
clrscr();
}
clrscr();
| ME | 3 |
| what is the diff b/w static and non static variables in C.
Give some examples plz. | Wipro | 2 |
| 2.main
{
int x,j,k;
j=k=6;x=2;
x=j*k;
printf("%d", x);
| HCL | 6 |
| What's the difference between struct x1 { ... }; and
typedef struct { ... } x2; ?
| | 2 |
| what is the value of 'i'?
i=strlen("Blue")+strlen("People")/strlen("Red")-strlen("green")
| Cadence | 3 |
| 1
232
34543
4567654
can anyone tell me how to slove this c question | | 3 |
| Why doesn't the code "a[i] = i++;" work? | | 2 |
| what is the use of #pragma pack, wer it is used? | | 1 |
| How many ways are there to swap two numbers without using
temporary variable? Give the each logic. | | 4 |
| N O S I E R
+ A S T R A L
----------------
7 2 5 6 1 3 | Honeywell | 1 |
| why TCS selected more student in the software field from
all institution. | TCS | 3 |
| consider the following structure:
struct num nam{
int no;
char name[25];
};
struct num nam
n1[]={{12,"Fred"},{15,"Martin"},{8,"Peter"},{11,Nicholas"}};
.....
.....
printf("%d%d",n1[2],no,(*(n1 + 2),no) + 1);
What does the above statement print?
a.8,9
b.9,9
c.8,8
d.8,unpredictable value
| TCS | 2 |
| main()
{char a[10]={1,2,3,4,5,6};int x;
for(x=0;x<4;x++){ b[x]=x+'a';}
printf("%s",b);}
| | 3 |
| write the program for prime numbers? | TCS | 7 |
| How the processor registers can be used in C ? | HP | 4 |
| WAP to accept basic salary of an employee?
Calculate it HRA=25%,DA=30%,PF=30%&net salary display all
contents? | | 3 |
| What is the output of the following program
#include<stdio.h>
main()
{
int i=0;
fork();
printf("%d",i++);
fork();
printf("%d",i++);
fork();
wait();
} | ADITI | 2 |
| 15.what is the disadvantage of using macros?
16.what is the self-referential structure?
17.can a union be self-referenced?
18.What is a pointer?
19.What is the Lvalue and Rvalue?
20.what is the difference between these initializations?
21.Char a[]=”string”;
22.Char *p=”literal”;
23.Does *p++ increment p, or what it points to? | | 1 |
| What's the difference between calloc() and malloc()? | | 2 |
| |
| For more C Interview Questions Click Here |