C Interview Questions
Questions Answers Views Company eMail

i=20,k=0; for(j=1;j

HCL,

8 20725

int i =10 main() { int i =20,n; for(n=0;n<=i;) { int i=10 i++; } printf("%d", i);

HCL, Octal, SW,

6 19996

f=(x>y)?x:y a) f points to max of x and y b) f points to min of x and y c)error

HCL,

4 6537

which of the function operator cannot be over loaded a) <= b)?: c)== d)*

Cisco, CTS, Google, HCL, HP,

10 37211

long int size a) 4 bytes b) 2 bytes c) compiler dependent d) 8 bytes

Acropolis, HCL, Intel, TCS,

18 37477

x=2,y=6,z=6 x=y==z; printf(%d",x)

Bharat, Cisco, HCL, TCS,

13 36645

int a=1,b=2,c=3; printf("%d,%d",a,b,c); What is the output?

Verifone,

14 27843

proc() { static i=10; printf("%d",i); } If this proc() is called second time, what is the output?

Hughes,

7 8146

int arr[] = {1,2,3,4} int *ptr=arr; *(arr+3) = *++ptr + *ptr++; Final contents of arr[]

Hughes,

6 12941

In scanf h is used for

BFL,

4 11211

what does " calloc" do?

Cadence, Logos,

7 11640

what does exit() do?

Cadence,

3 8568

what is the value of 'i'? i=strlen("Blue")+strlen("People")/strlen("Red")-strlen("green")

Cadence, JNTU, Zen Technologies,

7 15352

prototype of sine function.

Cadence,

2 7301

#define min((a),(b)) ((a)<(b))?(a):(b) main() { int i=0,a[20],*ptr; ptr=a; while(min(ptr++,&a[9])<&a[8]) i=i+1; printf("i=%d\n",i);}

3 14710


Post New C Questions

Un-Answered Questions { C }

Read N characters in to an array . Use functions to do all problems and pass the address of array to function. 1. Print only the alphabets . If in upper case print in lower case vice versa. 2. Enter alphanumeric characters and form 2 array alphaets and digits.Also print the count of each array. 3. Find the count of a certain character. 4. Print the positions where a certain character occured. 5. Print the characters between successive array elements. 6. Find the largest and smallest charcter. How many times it each one occured. 7. Enter a certain range. Print out the array elements which occured between these range. 8. Reverse a character array without using another array. 9. Reverse an array region. 10. Replace a the array elements with it next character . Use a after z. 11. Code the array element with certain character as first alphabet. 12. Duplicate all the vowels in a character array. What is the new count. 13. Delete the vowels in a character array. What is the new array count. 14. Print the count of all characters in the array. 15. Enter n alphabets and store a upto tht charcter in array.What is the array count? 16. Sort a character array. 17. Merge 2 character arrays largearray,smallarray. 18. Find the pair with largest number of characters in between. 19. Find the numerical value of a charcter array. 20. Store n numeral characters in an arrray. Insert another numeral character in a certain position. 21. Insert a character in a sorted array. 22. Merge 2 sorted arrays in sorted fashion. 23. Duplicate the least occuring character. 24. Write a menu driven program to circular right/left shift an array of n elements. 25. Is the character array palindrome? if not make it palindrome. 26. Concatenate the first n charaters to the end of the string. 27. Print all n group of chracters which are palindrome. 28. Concatneate the reverse of last n characters to the array.

3332


What is a pointer and how it is initialized?

589


hw can we delete an internal node of binary search tree the internal node has child node..plz write progarm

1619


Differentiate call by value and call by reference?

554


How many loops are there in c?

569






In which layer of the network datastructure format change is done

1419


In this assignment you are asked to write a multithreaded program to find the duplicates in an array of 10 million integers. The integers are between -5000,000 to 5000,000 and are generated randomly. Use 10 threads, each thread works on 1000,000 integers. Compare the time needed to accomplish the task with single thread of execution program. Do not include the time to fill the array with integers in the execution time.

2670


Why is extern used in c?

601


C language questions for civil engineering

1231


Explain what are the __date__ and __time__ preprocessor commands?

576


What is pragma c?

599


What is context in c?

528


WHAT IS THE DEFINATION OF IN TECHNOLOGY AND OFF TECHNOLOGY ?

1846


What is wrong with this statement? Myname = 'robin';

801


Explain what is the difference between the expression '++a' and 'a++'?

618