Community Sites
Create your own community website and start earning today !
It's Free !
 
Communities Members BookmarksPolls Fresher Jobs Funny Pictures MCA Projects New Member FAQ  



My Profile
Active Members
TodayLast 7 Days more...



Awards & Gifts
Online Exams

Fresher Jobs


Our fresher job section is exclusively for fresh graduates! Find jobs for freshers in major Indian cities including Bangalore, Chennai, Hyderabad, Pune or Kochi

Resources


Find educational articles, blogs, discussion threads and other resources.

Colleges


Find details about any college in India or search for courses.

website counter



INTERVIEW QUESTIONS ON C, C++.


Posted Date: 17 Jun 2008    Resource Type: News/Announcements    Category: Jobs & Interviews

Posted By: Lenin       Member Level: Diamond
Rating:     Points: 4



INTERVIEW QUESTIONS ON C, C++. GENERAL
What follows is a list of questions that I typically ask interview candidates. No, I'm not going to give you the answers - that's up to you. Someday, you'll be sitting across from me or someone like me, and they'll ask you questions like these.
When that happens, resist the temptation to give a pat, memorized answer. You should be able to take any one of these questions, and talk about each one with an interviewer for at least five minutes or so. The type of candidate that really impresses me is not the one who can answer using the fewest words, it's the one that knows something well, and can explain it to me.

General Questions

These are questions I tend to ask at the beginning or at then end of an interview. There are no right or wrong answers - the intent is to find out more about a candidate, and to get them comfortable talking about themselves.
How did you get into computer science?
What kind of technical publications (print or online) do you read on a regular basis?
What was the last book you read (does not have to be job related!)
If you could recommend one resource (book, web site, etc.) to a new software developer just out of school, what would it be?
What was the most interesting project that you worked on?
What was the most challenging project that you worked on?
If you could have any job in the world, what would it be?

C++ Questions
What are the major differences between C and C++?
What are the differences between new and malloc?
What is the difference between delete and delete[]?
What are the differences between a struct in C and in C++?
What are the advantages/disadvantages of using #define?
What are the advantages/disadvantages of using inline and const?
What is the difference between a pointer and a reference?
When would you use a pointer? A reference?
What does it mean to take the address of a reference?
What does it mean to declare a function or variable as static?
What is the order of initalization for data?
What is name mangling/name decoration?
What kind of problems does name mangling cause?
How do you work around them?
What is a class?
What are the differences between a struct and a class in C++?
What is the difference between public, private, and protected access?
For class CFoo { }; what default methods will the compiler generate for you>?
How can you force the compiler to not generate them?
What is the purpose of a constructor? Destructor?
What is a constructor initializer list?
When must you use a constructor initializer list?
What is a:
Constructor?
Destructor?
Default constructor?
Copy constructor?
Conversion constructor?
What does it mean to declare a...
member function asvirtual?
member function asstatic?
member function asstatic?
member varible as static?
destructor as static?
Can you explain the term "resource acqusition is initialization?"
What is a "pure virtual" member function?
What is the difference between public, private, and protected inheritance?
What is virtual inheritance?
What is placement new?
What is the difference between operator new and the new operator?
What is exception handling?
Explain what happens when an exception is thrown in C++.
What happens if an exception is not caught?
What happens if an exception is throws from an object's constructor?
What happens if an exception is throws from an object's destructor?
What are the costs and benefits of using exceptions?
When would you choose to return an error code rather than throw an exception?
What is a template?
What is partial specialization or template specialization?
How can you force instantiation of a template?
What is an iterator?
What is an algorithm (in terms of the STL/C++ standard library)?
What is std::auto_ptr?
What is wrong with this statement? std::auto_ptr ptr(new char[10]);
It is possible to build a C++ compiler on top of a C compiler. How would you do this? (Note: I've only asked this question once; and yes, he understood that I was asking him how cfront was put together. We hired him.)/i>
Code Snippets
I like to put these up on a whiteboard, and ask questiosn about them.

What output does the following code generate? Why?
What output does it generate if you make A::Foo() a pure virtual function?
#include

class A {
public:
A() {
this->Foo();
}
virtual void Foo() {
cout << "A::Foo()" << endl;
}
};

class B : public A {
public:
B() {
this->Foo();
}
virtual void Foo() {
cout << "A::Foo()" << endl;
}
};

int main(int, char**)
{
B objectB;

return 0;
}


What output does this program generate as shown? Why?
#include

class A {
public:
A() {
cout << "A::A()" << endl;
}
~A() {
cout << "A::~A()" << endl; throw "A::exception";
}
};

class B {
public:
B() {
cout << "B::B()" << endl; throw "B::exception";
}
~B() {
cout << "B::~B()";
}
};

int main(int, char**) {
try {
cout << "Entering try...catch block" << endl;

A objectA;
B objectB;

cout << "Exiting try...catch block" << endl;
} catch (char* ex) {
cout << ex << endl;
}

return 0;
}


Misc. Questions

What's the difference between SQL, DDL, and DML?
What's a join? An inner join? An outer join?
Describe HTTP.
What's a design pattern?
Can you explain the singleton, vistor, facade, or handle class design pattern?




Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
(No tags found.)

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: JAVA INTERVIEW QUESTIONS
Previous Resource: Walk-in-interview for Computer Assistant on 24th June 2008 in DCETA
Return to Discussion Resource Index
Post New Resource
Category: Jobs & Interviews


Post resources and earn money!
 
Related Resources



Watch TV Channels
  • Watch Asianet TV online
  • Kairali TV in Internet
  • Surya TV online
  • Amritha TV Channel

  • Contact Us    Privacy Policy    Terms Of Use   

    SpiderWorks Technologies Pvt Ltd. 2006 - 2007 All Rights Reserved.