C++ Interview Questions
Questions Answers Views Company eMail

Implement strcmp

Bloomberg, Citadel,

3 8263

Implement strncpy

3 8966

how can u create a doubly linked list with out using pointers?

2 4613

Write a program using GUI concept for the scheduling algorithms in Operating system like SJF,FCFS etc..

3360

Base class has two public data members. How can i derive a new class with one datamember as public and another data member as private?.

2 5116

how can i access a direct (absolute, not the offset) memory address? here is what i tried: wrote a program that ask's for an address from the user, creates a FAR pointer to that adress and shows it. then the user can increment/decrement the value in that address by pressing p(inc+) and m(dec-). NOW, i compiled that program and opened it twice (in 2 different windows) and gave twice the same address to it. now look what happen - if i change the value in one "window" of the program, it DOES NOT change in the other! even if they point to the same address in the memory! here is the code snippet: //------------------------------------------------------ #include //INCLUDE EVERY KNOWN HEADER FILE #include //FOR ANY CASE... #include #include #include main() { int far *ptr; //FAR POINTER!!! long address; char key=0; //A KEY FROM THE KEYBOARD int temp=0; clrscr(); cout<<"Enter Address:"; cin>>hex>>address; //GETS THE ADDRESS clrscr(); (long)ptr=address; temp=*ptr; //PUTS THE ADDRESS IN THE PTR cout<<"["< 1821


explain dynamic binding by drowing

Cognizant,

2 6184

how can we design a magic square in c++?or suggest me the basic idea of it.

3 7310

What is the differances between a abstract calss and interface

Aviva, Symphony,

5 9247

why we cant create array of refrences

4 6405

what is difference b/w object based and object oriented programming language?

Chaitanya, College School Exams Tests, Educomp, IBM, Infosys, Telko,

18 41929

I am doing my BS.c MATHS CAN I ABLE TO JOIN IN NIIT?

2 3632

what is multithreading in c++ , what is difference between multithreading and singlethreading.

4 33128

What are the advantanges of modularity

2 13786

How to handle exception in c++, For example in a functions i am assigning memory to some variables and also in next instructions in am dividing one variable also. If this functions generates a error while allocating memory to those variable and also while dividing the variable if i divide by zero then catch block how it will identify that this error has cone from perticular instruction

1654


Un-Answered Questions { C++ }

Define a nested class.

615


C is to C++ as 1 is to a) What the heck b) 2 c) 10

641


What is one dimensional array in c++?

582


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

1991


What are c++ storage classes?

620






Which one between if-else and switch is more efficient?

604


Discuss the role of C++ shorthands.

549


Explain the operation of overloading of an assignment operator.

698


If you want to share several functions or variables in several files maitaining the consistency how would you share it?

554


IS IT NECESSARY TO INITIALIZE VARIABLE? WHAT IF THE INSTANCE VARIABLE IS DECLARED final ? IS IT NECESSARY TO INITIALIZE THE final VARIABLE AT THE TIME OF THEIR DECLARATION?

1583


Name the implicit member functions of a class.

600


Why are arrays usually processed with for loop?

775


Can a program run without main?

631


the maximum length of a character constant can be a) 2 b) 1 c) 8

602


What is time h in c++?

587