C Interview Questions
Questions Answers Views Company eMail

Write a routine that prints out a 2-D array in spiral order!

Lucent,

1 5389

what is a far pointer

ITI, ABB, TCS, Steel Plant, DRDO, Vivo Mobiles, Maruti Suzuki, Toyota,

12 25422

Write a program to compare two strings without using the strcmp() function

Accenture, Arba Minch University,

42 100073




what is the difference between const char *p, char const *p, const char* const p

Verizon, CTS, Aricent, Accenture, Geometric Software, Point Cross,

5 43738

Write a program to interchange two variables without using the third variable?

Infotech, Accenture, College School Exams Tests,

17 25208

What is the output of the program given below #include main() { char i=0; for(;i>=0;i++) ; printf("%d\n",i); }

TCS, ADITI, Student,

21 16603

What is the output of the following program #include main() { int i=0; fork(); printf("%d",i++); fork(); printf("%d",i++); fork(); wait(); }

Adobe, ADITI,

8 10955

What is the memory allocated by the following definition ? int (*x)[10];

Wipro, ADITI,

4 10794




What is the memory allocated by the following definition ? int (*x)();

ADITI,

2 6073

What is the output for the program given below typedef enum grade{GOOD,BAD,WORST,}BAD; main() { BAD g1; g1=1; printf("%d",g1); }

ADITI,

4 5661

Give the output for the following program. #define STYLE1 char main() { typedef char STYLE2; STYLE1 x; STYLE2 y; clrscr(); x=255; y=255; printf("%d %d\n",x,y); }

ADITI,

2 4202

#ifdef TRUE int I=0; #endif main() { int j=0; printf("%d %d\n",i,j); }

ADITI,

3 4358

What is the output for the following program #include main() { char a[5][5],flag; a[0][0]='A'; flag=((a==*a)&&(*a==a[0])); printf("%d\n",flag); }

Wipro, ADITI,

5 5376

HOW DO YOU HANDLE EXCEPTIONS IN C?

AppLabs,

2 4431

WHAT IS THE DIFFERENCE BETWEEN malloc() and calloc() in c file management?

Deltech, IBM, 3D PLM, Code Studio,

28 65994


Post New C Questions






Un-Answered Questions { C }

write a program to convert a expression in polish notation(postfix) to inline(normal) something like make 723+* (2+3) x 7 (not sure) just check out its mainly printing expression in postfix form to infix.

1437


Why is event driven programming or procedural programming, better within specific scenario?

1168


Write the test cases for checking a variable having value in range -10.0 to +10.0?

902


write a c program to print the next of a particular no without using the arithmetic operator or looping statements?

2053


string reverse using recursion

1044






why return type of main is not necessary in linux

912


how to find anagram without using string functions using only loops in c programming

1882


4-Take two sets of 5 numbers from user in two arrays. Sort array 1 in ascending and array 2 in descending order. Perform sorting by passing array to a function mySort(array, sortingOrder). Then multiply both the arrays returned from function, using metric multiplication technique in main. Print result in metric format.

813


illustrate the use of address operator and dereferencing operator with the help of a program guys plzzz help for this question

741


plz let me know how to become a telecom protocol tester. thank you.

962


You have given 2 array. You need to find whether they will create the same BST or not. For example: Array1:10 5 20 15 30 Array2:10 20 15 30 5 Result: True Array1:10 5 20 15 30 Array2:10 15 20 30 5 Result: False One Approach is Pretty Clear by creating BST O(nlogn) then checking two tree for identical O(N) overall O(nlogn) ..we need there exist O(N) Time & O(1) Space also without extra space .Algorithm ?? DevoCoder guest Posted 3 months ago # #define true 1 #define false 0 int check(int a1[],int a2[],int n1,int n2) { int i; //n1 size of array a1[] and n2 size of a2[] if(n1!=n2) return false; //n1 and n2 must be same for(i=0;ia1[i+1]) && (a2[i]>a2[i+1]) ) ) return false; } return true;//assumed that each array doesn't contain duplicate elements in themshelves }

1847


what is the basis for selection of arrays or pointers as data structure in a program

2967


find out largest elemant of diagonalmatrix

810


A program is required to print your biographic information including: Names, gender, student Number, Cell Number, line of study and your residential address.

505


hai iam working in sap sd module for one year and working in lumax ind ltd in desp department but my problem is i have done m.b.a in hr/marketing and working sap sd there is any combination it. can you give right solution of my problem. and what can i do?

912