| Other C++ General Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| Given a simple program designed to take inputs of integers
from 1-1000 and to output the factorial value of that
number, how would you test this program? You do not have
access to the code. Please be as specific as possible.
| Microsoft | 2 |
| What are Virtual Functions? How to implement virtual
functions in "C" ? | | 2 |
| How do you know that your class needs a virtual destructor? | Lucent | 3 |
| What is conversion constructor? | TCS | 1 |
| What is the difference between Pointer and a Reference?
When you would use them? | Wipro | 2 |
| Difference between Overloading and Overriding? | HP | 4 |
| What is "strstream" ? | Huawei | 1 |
| Why would you make a destructor virtual? | Lehman-Brothers | 3 |
| Can we declare destructor as static? Explain? | | 2 |
| How to implement flags? | Symphony | 1 |
| what is the behaviour of C and C++ compiler for the below
statements.
int *p;
p = malloc(100);
Is the behaviour same ? or different ? | | 1 |
| why the size of an empty class is 1 | | 3 |
| What is object slicing and how can we prevent it? | Tech-Mahindra | 2 |
| write the prime no program in c++? | | 4 |
| What are the different types of polymorphism? | | 2 |
| How can you find the nodes with repetetive data in a linked
list? | Lucent | 1 |
| What is your strongest programming language (Java, ASP, C,
C++, VB, HTML,C#, etc.)? | Microsoft | 20 |
| const char *
char * const
What is the differnce between the above two? | TCS | 8 |
| Write a program to swap 2 chars without using a third
varable?
char *s = "A";
char *p = "B"; | CTS | 3 |
| what is importance of data sturture in a programming
language? | L&T | 10 |
| |
| For more C++ General Interview Questions Click Here |