| Other C++ General Interview Questions |
| |
| Question | Asked @ | Answers |
| |
| What is your strongest programming language (Java, ASP, C,
C++, VB, HTML,C#, etc.)? | Microsoft | 20 |
| What are the types of STL containers? | | 1 |
| how can u create a doubly linked list with out using
pointers? | | 1 |
|
1. What does the following do:
void afunction(int *x)
{
x=new int;
*x=12;
}
int main()
{
int v=10;
afunction(&v);
cout<<v;
}
a) Outputs 12
b) Outputs 10
c) Outputs the address of v
| Quark | 3 |
| Do we have private destructors? | Symphony | 9 |
| When the design recommends static functions? | Symphony | 1 |
| how to swap two strings without using any third variable ? | | 3 |
| What is difference between initialization and assignment? | HP | 4 |
| Write the program form Armstrong no in c++? | | 4 |
| why the size of an empty class is 1 | | 3 |
| Memory is not a constraint. In a single iteration(NOTE: you
can't go back), how will you find out the 10th last
node/item in a linked list. | Goldman-Sachs | 8 |
| Explain the difference between 'operator new' and the 'new'
operator? | Lucent | 1 |
| In C++ cout is:
a) object
b) class
c) something else | Lehman-Brothers | 10 |
| What is design pattern? | Samsung | 2 |
| What and all can a compiler provides by default? | HP | 3 |
| What are the different types of Storage classes? | | 3 |
| Evaluate:
int fn(int v)
{
if(v==1 || v==0)
return 1;
if(v%2==0)
return fn(v/2)+2;
else
return fn(v-1)+3;
}
for fn(7);
a) 10
b) 11
c) 1
| Quark | 1 |
| What is Virtual Inheritance? | Wipro | 2 |
| Describe functional overloading? | HP | 3 |
| The "virtual" specifier in a member function enables which
one of the following?
a) Monmorphism
b) Late binding
c) Metamorphism
d) Solomorphism
e) Inheritance
| Quark | 3 |
| |
| For more C++ General Interview Questions Click Here |