Interview questions

C interview questions – page 56

2,094 questions. Tap “Show answer” to check yourself.

  1. How can i make a program with this kind of output..Enter a number: 5001012012301234012345012340123012010

  2. Pointer_variable=(typecastingdatatype*)malloc(sizeof(datatype));This is the syntax for malloc? Please explain this,how it work with an example?

  3. An entire structure variable can be assigned to another structure variable if __________

  4. How can we open a file in Binary mode and Text mode?what is the difference?

  5. Pgm to find number of words starting with capital letters in a file(additional memory usage not allowed)(if a word starting with capital also next letter in word is capital cann't be counted twice)

  6. How to find the given number is prime or not?

  7. Write a program that input four digit no and finds it is palindrome or not

  8. Generally variables are stored in heap memory. When hevariables are created in stack?

  9. Can you change name of main()?how?

  10. If there is binary tree which one is the easiest way todelete all child node?

  11. What will happen if you free a pointer twice afterallocating memory dynamically ?

  12. Write aprogram forThere is a mobile keypadwith numbers 0-9 and alphabets on it. take input of 7 keysand then form aword from the alphabets present on those keys.

  13. What is conditional Compilation?

  14. WHAT IS PRE POSSESSORS?

  15. What is cast operator?

  16. Write a C++ programming :if the no is between 32 to 50 itwill be odd.

  17. Program to find the absolute value of given integer usingConditional Operators

  18. Is there any difference between dlearations int* x and int *x? If so tell me the difference?

  19. C statement to copy a string without using loop and libraryfunction..

  20. What is the difference between. system call and libraryfunction?

  21. Write a program to find the number of even integers and oddintegers in a given array in c language

  22. What is difference between Convert.ToString(variable) andvariable.ToString()

  23. If the static variable is declared as global,will it be same as extern?

  24. What does keyword ?extern? mean in a function declaration?

  25. Write a c pgm for leap year

  26. How to swap two integers 1 and 32767 without using thirdvariable

  27. I can i set size of integer variable should be fixed for different operating systems(Ex i want integer size is 2bytes in OS)

  28. Write a own function to compare two strings with out usingstringcomparition function?

  29. Find second largest element in array w/o using sorting techniques? use onle one for loop.

  30. Write a function that accepts a sentence as a parameter, andreturns the same with each of its words reversed. Thereturned sentence should have 1 blank space between eachpair of words.Demonstrate the usage of this function from a main program.Example:Parameter: ?jack and jill went up a hill? Return Value:?kcaj dna llij tnew pu a llih?

Companies that ask C questions