What is the difference between classes and structures?
Explanation
Structures (just like classes) can have its name, fields and member-functions. But fields and member-functions have public access modifier by default in case of structures while it is private for classes. Same modifiers are in place by default in case of base class inheritance. There is no more difference between classes and structures.

Follow CodeGalaxy

Mobile Beta

Get it on Google Play
Send Feedback
Cosmo
Sign Up Now
or Subscribe for future quizzes