C Interview Questions

What is Heap?

4472

Is there any algorithm to search a string in link list in the minimum time?(please do not suggest the usual method of traversing the link list)

792

how to add numbers without using arithmetic operators.

TCS,

7382

if a person is buying coconuts of Rs10,and then sell that coconuts of Rs9,with the loss of one rupee.After that the person became a millaniore.how?

5305

a 'c' program to tell that the set of three coordinates lie on a same line

10029

write a program to print sum of each row of a 2D array.

20803

write a program to arrange the contents of a 1D array in ascending order

15079

What will be the output of x++ + ++x?

27183

write a Program to dispaly upto 100 prime numbers(without using Arrays,Pointer)

63865

how is the examination pattern?

814

Find Error if any in below code, Justify ur answer: struct xx { int a; struct yy { char c; struct xx* p; } struct yy* q; }

NDS,

4548

main() { int i = 1; int num[] = {1,2,3,4}; num[i] = i++; printf("%d", num[i]); } what will be the output? }

TCS, NDS,

16286

#define MAX(x,y) (x) > (y) ? (x) : (y) main() { int i = 10, j = 5, k = 0; k = MAX(i++, ++j); printf("%d %d %d", i,j,k); } what will the values of i , j and k? }

GATE, CDAC, TCS, NDS,

25949

fun(int x) { if(x > 0) fun(x/2); printf("%d", x); } above function is called as: fun(10); what will it print? }

NDS,

10066

#define DCHAR char* typedef char* TCHAR; if using these following variables will be declared like DCHAR ch1, ch2; TCHAR ch3, ch4; then what will be types of ch1, ch2, ch3 and ch4?

NDS,

5825

Write a C program to count the number of email on text

692

program to convert a integer to string in c language'

1040

what are bit fields? What is the use of bit fields in a structure declaration?

701

The purpose of this exercise is to benchmark file writing and reading speed. This exercise is divided into two parts. a). Write a file character by character such that the total file size becomes approximately >10K. After writing close the file handler, open a new stream and read the file character by character. Record both times. Execute this exercise at least 4 times b). Create a buffer capable of storing 100 characters. Now after generating the characters, first store them in the buffer. Once the buffer is filled up, store all the elements in the file. Repeat the process until the total file size becomes approximately >10K.While reading read a while line, store it in buffer and once buffer gets filled up, display the whole buffer. Repeat the exercise at least 4 times with different size of buffer (50, 100, 150 …). Records the times. c). Do an analysis of the differences in times and submit it in class.

773

given post order,in order construct the corresponding binary tree

1553

how to write a c program to print list of fruits in alpabetical order?

662

1042

What is the difference between declaring a variable by constant keyword and #define ing that variable?

1496

583

i want to switch my career from quailty assurance engineering to development kindly guide me from which programming language its better for me to start plz refer some courses or certifications too i have an experience of 1.5 yrs in QA field.Kindly guide me

706

i have a written test for microland please give me test pattern

1302

praagnovation

735

write a program that reads lines(using getline), converts each line to an integer using atoi, and computes the average of all the numbers read. also compute the standard deviation.

1064

How to establish connection with oracle database software from c language?

870

1) write a program to generate 1st n fibonacci prime numbers using Nested if 2) write a program to generate twin prime numbers from m to n using nested if 3) write a program to check whether a given integer is a strong number or not using nested if 4) Write a program to generate prime factors of a given integer using nested if 5)write a program to generate prime numbers from m to n using nested if 6)write a program to generate perfect numbers from m to n using nested if 7)write a program to generate the pallindromes from m to n using neste if 8)write a program to generate armstrong numbers from m to n using nested if 9)write a program to generate strong numbers from m to n using nested if

3191