You are on page 1of 3

Few Viva Question

1. What is the difference between runtime error and syntax error?
2. What is purpose of header file?
3. Why main() is special?
4. What is the difference between #define and const?
5. What are preprocessor directives?
6. What do you understand by typedef?
7. How typedef is different from #define?
8. What do understand by nested structure?
9. What is a class and object?
10. Define data hiding in terms of oops?
11. What is nested classes and how it is different from containership and inheritance?
12. What do you mean by function prototyping?
13. Differentiate between local variable and global variable.
14. What do you understand by a pointer?
15. What is the initial value of a pointer?
16. Name the arithmetic application you can do pointer variable?
17. In int a[10]; what is a? how can you initialize a pointer p to hold value of a?
18. What is the putpose of **a?
19. How do we refer to a member through pointer of a class?
20. Define the following term:
(i) Encapsulation (ii) Abstraction (iii) Data hiding (iv) Inheritance
21. Differentiate between public, protected and private members?
22. Differentiate between structure and classes
23. What do you understand by reference variable?
24. What do you understand by lvalue and Rvalue of a variable?
25. What do you understand by :: (scope resolution) operator?
26. What is difference between : and :: operator?
27. What is typecasting ?
28. What is the benefit of declaring a data member as protected?
29. What is the visibility modes?
30. Differentiate between private, protected and public visibility mode?
31. What is visibility mode in a class?
32. What is inline functions?
33. How to declare a function as inline in a class?
34. What are methods of defining a member function?
35. Why a constructor is public member of class?
36. When a copy constructor is invoked?
37. Differentiate between Call by reference and Call by value.
38. Can private members of the base class be accessed by the derived class? If yes, how?
39. What is circular queue? How is it different from simple queue?
40. When will you make a function inline?
41. Which of the following sorting :
a. Selection sort
b. Bubble sort
c. Insertion sort
i. Is more efficient?

How is constructor overloading different from function overloading? 24. Define self-referential structure with suitable examples 34. 11. What is meant by term ‘literal’ in Boolean algebra? 36. What is a ‘this’ pointer ? 41. What is the difference between get and getline()? 16. What is application of K-map? 39. What do understand by virtual inheritance? 26. What are methods of opening a file? 14. Explain parameter of read() or write()? 18. AND. What is a friend function? 23. OR gates? 37. What is the difference between put() and write()? 12. What is the precondition for Binary search to be performed on a single dimensional array? 21. What is the purpose of eof()? 15. What is significance of top in stack? 31. Give two applications of queue? 29. Give names of two member functions belonging fstream class. Give any two applications of stack? 28. What is purpose of dqueue? [ Dqueue is double ended queue to enter and delete data from both the sides] 32. What is the difference between LIFO and FIFO ? 40. What is the purpose of destructor in class for linked stack or queue? 33. Explain different types of Inheritance? 25. Differentiate between ifstream class and ofstream class ? 9. Define (i) Default constructor (ii) Parameterized constructor (iii) Copy constructor (iv) Destructor 27. 10. Explain parameters of getline()? 17. What is duality principle in Boolean algebra? 38. Name two common member functions belonging to ifstream and ofstream. o ios::out and ios::nocreate o ios::out and ios::noreplace o ios::nocreate and ios::noreplace o ios::out and ios::beg o seekg and seekp o seekg and tellg 20.8. Name one method to check if the file exists? 19. What is the purpose of tellg()? 13. What is primary key? 42. Distinguish between o ios::out and ios::app. What do understand by signature of a function? 22. Why are NAND and NOR gates more popular than the basic NOT. What is foreign key?What is its purpose 43. What is the significance of front and rear in a queue? 30. What is purpose of circular queue and how it is different from static queue? 35. What do you mean by candidate key and how it is different from alternate key? .

What do you understand by the terms Cardinality and Degree of the table? 47. Write some features of SQL? 52. What do you understand by constraints ? 51. What is the precondition of drop table? .44. Define the terms Tuple and Attribute 46. What is difference between drop table and drop view? 56. What is the main function of DBA. What are group Functions 54. What is Cartesian product of two tables? 45. What is the difference between Where and Having Clause ? 50. What are DDL and DML? 49. 48. What is difference between order by and group by? 55. Write various database objects available in SQL? 53.