what is the difference between class and structure in C++?

Answer Posted / naveen tuteja

A structure can't contain the static ans constant variable
but a class can contain both.

Is This Answer Correct ?    4 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the components of marker interface?

807


Write a C++ program without using any loop (if, for, while etc) to print prime numbers from 1 to 100 and 100 to 1 (Do not use 200 print statements!!!)

1855


What is oops and its features?

836


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?

1824


class type to basic type conversion

2097


officer say me - i am offered to a smoking , then what can you say

1852


What is basic concept of oop?

907


What is meant by multiple inheritance?

954


what is difference between class template and template class?

2408


What is the problem with multiple inheritance?

840


What is polymorphism in oop example?

746


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?

1896


What is the difference between a constructor and a destructor?

860


How do you explain polymorphism?

809


What is an interface in oop?

785