Interview questions

C interview questions – page 51

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

  1. What are constructors and destructors

  2. How do you create multiple inheritance in C#?

  3. What is Difference Between Inheritance and creating object and getting data? meansClass A extends B{B.getMethod();}(OR)Class A{b obj=new B();obj.getMethod();}

  4. What is the difference between fork() & exec()

  5. I created a class which is inherited from interfaceIDisposable. Now if I use object of this class with usingkeyword. Then How the dispose method will get call. Doesgarbage collector call it or some else.

  6. Differences between Java and C++? which is faster?

  7. ? What is an intermediate language?

  8. What are three tenets of object orinted Systems? Why they call like that ?

  9. What is the renewal class?

  10. What is a delegate? what it is used for?

  11. Write a C/C++ program that connects to a MySQL server andchecks intrusion attempts every 5 minutes. If an intrusionattempt is detected beep the internal speaker to alert theadministrator. A high number of aborted connects to MySQL ata point in time may be used as a basis of an intrusion.

  12. Can you overload a method of class A in Class B if it isderived class of A? If it is yes tell me how is it possible?

  13. Can we create instance for Abstract class?

  14. Write a program in c++ to implement stack using functions in header file stack.h

  15. What are callback functions in c++

  16. Trace the O/p for a program on inheritance and Polymorphism. 3 classes A,B,C A with two methods public virtual SomeMethodA public virtual SomemoreMethodA B:A overide SomeMethodA C:B new Method SomeMethodA override SomeMoreMethodA main method { b new instance of B b.SomeMethodA b.SomeMoreMethodA b1 new instance of C b1.SomeMethodA b1.SomeMoreMethodA }

  17. Write pseudo code for push in a stack?

  18. Pointers are support in C#? if yes then how to use it?

  19. Write a function that accepts two numbers,say a and b and makes bth bit of a to 0.No other bits of a should get changed.

  20. What is the Maximum Size that an Array can hold?

  21. What is the main difference between c and c++?

  22. What is the difference between value types and reference types?

  23. What is the main differnce between const,readonly and static

  24. What is Hashing and how is it done? Pictorial form?

  25. Like int main (){Int i=65;Return printf(?%c?, i);}

  26. WHAT IS THE DIFFERENCE BETWEEN ABSTRUCTION AND ENCAPSULATION?PLEASE EXPLAIN IT.

  27. Why c++ is called c++ and not c+?

  28. What is difference b/w object based and object oriented programming language?

  29. .4.Why an empty structure occupy 2 bytes memory?

  30. Give the output of the following programmain(){char *p='a';int *i=100/*p;}what will be the value of *i= 1

Companies that ask C questions