What happen if we does not use class ? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

What happen if we does not use class ?

22nd May 2018, 3:54 AM
Puneet Bhardwaj
Puneet Bhardwaj - avatar
7 Answers
+ 7
You cannot create objects if you don't use a class :D s̶t̶r̶i̶k̶e̶t̶h̶r̶o̶u̶g̶h̶
22nd May 2018, 5:07 AM
Dev
Dev - avatar
+ 6
C, the ancestor of C++, didn't support classes and it worked. They are a great feature, though. And if you do it right, they consume literally zero additional performance.
22nd May 2018, 3:04 PM
Timon Paßlick
+ 4
I don't use class. It depends on the type of project you are creating.
22nd May 2018, 4:15 AM
Sachin Artani
Sachin Artani - avatar
+ 3
Dev how do you made your text strike through, For me its not possible in the comments section
22nd May 2018, 5:22 AM
scientist
scientist - avatar
+ 3
no class=no OOP'S= no private members = no objects =insecure code = and much more drawbacks.
22nd May 2018, 5:28 AM
Gaurav bhojwani
Gaurav bhojwani - avatar
+ 2
Well, nothing? It depends on your task whether to use classes (OOP style) or not
22nd May 2018, 3:59 AM
Matthias
Matthias - avatar