Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

explain defference between structure and class with example

Answer Posted / padmas

The structure, data type available in C is defined as Class in C plus plus. Where the data member variables in structure are accessible by all functions, methods. In Class the data variables and methods are encapsulated in one class with explicit accessible feature as public or private to protect the data. the data can also be protected with protect feature which is not available in structure data type. the only difference is data protection.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

They started with the brief introduction followed by few basic C++ questions on polumorphism, inheritance and then virtual functions. What is polymorphims? How you will access polymorphic functions in C? How virtual function mechanism works?

1869


What is a class and object?

1002


Can destructor be overloaded?

978


What makes a language oop?

1007


Give two or more real cenario of virtual function and vertual object

2285


What is encapsulation example?

984


i=20;k=0; for(j=1;k-i;k+=j<10?4:3) { cout<

1810


I have One image (means a group photo ) how to split the faces only from the image?............ please send the answer nagadurgaraju@gmail.com thanks in advace...

2050


what are the different types of qualifier in java?

2217


How to hide the base class functionality in Inheritance?

1090


Why it is called runtime polymorphism?

1048


Is react oop?

1014


Can a varargs method be overloaded?

1038


class type to basic type conversion

2338


What is the real time example of encapsulation?

1007