C Interview Questions
Questions Answers Views Company eMail

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

Lucent,

1 5530

what is a far pointer

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

12 26271

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

Accenture, Arba Minch University,

42 101415




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

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

5 44350

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

Infotech, Accenture, College School Exams Tests,

17 26472

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 17215

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 11325

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

Wipro, ADITI,

4 11123




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

ADITI,

2 6228

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 5853

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 4325

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

ADITI,

3 4510

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 5583

HOW DO YOU HANDLE EXCEPTIONS IN C?

AppLabs,

2 4568

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

Deltech, IBM, 3D PLM, Code Studio,

28 67010


Post New C Questions






Un-Answered Questions { C }

Explain output of printf("Hello World"-'A'+'B'); ?

227


Hai,I have done with my bachelor of commerce and planing to ms,please suggest me how to convince vo for shifting from commerce to computers. Visa on 8 DEC 2014  Npu university

883


You are to write your own versions of strcpy() and strlen (). Call them mystrcpy() and mystrlen(). Write them first as code within main(), not as functions, then, convert them to functions. You will pass two arrays to the function in the case of mystrcpy(), the source and target array.

1041


write a program that declares an array of 30 elements named "income" in the main functions. then cal and pass the array to a programmer-defined function named "getIncome" within the "getIncome" function, ask the user for annual income of 30 employees. then calculate and print total income on the screen using the following function: "void getIncome ( ai []);

1049


Write a program to compute the similarity between two strings - The program should get the two strings as input - Then it will output one single number which is the percentage of similarity between the two strings

1533






how is the examination pattern?

893


Create a structure to specify data on students given below: Roll number, Name, Department, Course, Year of joining Assume that there are not more than 450 students in the college. 1.write a function to print names of all students who joined in a particular year 2.write a function to print the data of a student whose roll number is given

1121


Write a C Program That Will Count The Number Of Even And Odd Integers In A Set using while loop

982


Write a C program that will accept a hexadecimal number as input and then display a menu that will permit any of the following operations to be carried out: Display the hexadecimal equivalent of the one's complement. (b) Carry out a masking operation and then display the hexadecimal equivalent of the result. (c) Carry out a bit shifting operation and then display the hexadecimal equivalent of the result. (d) Exit. If the masking operation is selected, prompt the user lor the type of operation (bitwise and, bitwise exclusive or, or bitwise or) and then a (hexadecimal) value for the mask. If the bit shifting operation is selected. prompt the user for the type of shift (left or right), and then the number of bits. Test the program with several different (hexadecimal) input values of your own choice.

3650


write a program to reverse a every alternetive words in a string in a place. EX: Input is "this is the line of text" Output should be "shit is eht line fo text" Please any one tell me code for that.

848


WRITE A CODE IN C TO SEARCH A FILE FROM NOTEPAD FILE.

1265


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?

970


Why is it important to memset a variable, immediately after allocating memory to it ?

864


Write a program to produce the following output: 1 2 3 4 5 6 7 8 9 10

10261


write a program to create a sparse matrix using dynamic memory allocation.

3570