what is the difference between class and structure in C++?
Answer Posted / navneet kaur
c is a procedure oriented language but c++ is a object
oriented language.
| Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
write knight tour problem which is present in datastructure
Can we create object of abstract class?
#include
Give an example where we have to specifically use C programming language and C++ programming language cannot be used?
What is inheritance and how many types of inheritance?
Why do we use encapsulation in oops?
INSTANCE FIELDS DECLARED private ARE ACCESSIBLE BY THE METHODS ONLY.CAN WE CHANGE THE private FIELD OF AN OBJECT IN A METHOD OF SOME OTHER OBJECT OF THE SAME CLASS?
class CTest { public: void someMethod() { int nCount = 0; cout << "This is some method --> " << nCount; } }; int main() { CTest *pctest; pctest->someMethod(); return 0; } It will executes the someMethod() and displays the value too. how is it possible with our creating memory for the class . i think iam not creating object for the class. Thanks in Advance... Prakash
String = "C++ is an object oriented programming language.An imp feature of oops is classes and objects".Write a pgm to count the repeated words from this scenario?
What is Difeerence between List obj=new ArrayList(); and ArrayList obj=new ArrayList()?
What is the important feature of inheritance?
Write a program to compute for numeric grades for a course. The course records are in a file that will serve as the input file. The input file is in exactly the following format: Each line contains a student's first name, then one space, then ten quiz scores all on one line. The quiz scores are in whole number and are separated by one space. Your program will take it input from this file and sends it output to a second file. The data in the output file will be exactly the same as the data in the input file except that there will be one additional number (of type double) at the end of each line. This number will be the average of the student's ten quiz scores. Use at least one function that has file streams as all or some of its arguments.
What is difference between polymorphism and inheritance?
Why is abstraction used?
Why can't we have instance(stack) of a class as a member of the same class like eg.Class A{A obj;} as we can have self refential pointer