0
Is Class is same as Structure and Union ?
4 odpowiedzi
+ 2
kind of . but structures were originally created to store variables of different data types. Functions can also be added to them as the object oriented model allows. but they dont support Inheritance because they were not actually the intrest of object orinted model. A Class is more better than a structure coz it support OOP in encapsulation and Inheritance.
0
Class is the same as structure
0
inheritance
0
No, a class has methods and store data. Structure is only for store data and Union is for multiple type data on one var.