Classes and structures | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Classes and structures

Classes and structures, which of them are more easier and friendlier?

4th May 2017, 9:18 AM
Tsadidey Fortune Selassie
Tsadidey Fortune Selassie - avatar
1 Answer
0
assuming you're talking of C/C++ struct vs C++ classes (OOP), structs are easiest to handle as they are only data embeding, while class could embed also logic (funxtions/methods) related to datas... classes could do more than structs, but structs are easier friendly to deal: structs are avaimable in C AND C++, while classes only in C++ ^^
9th Apr 2021, 12:10 AM
visph
visph - avatar