What should sample code contain i.e. constructor, encapsulation, private members etc. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

What should sample code contain i.e. constructor, encapsulation, private members etc.

sample code for potential employers.

24th Feb 2017, 3:16 PM
Jay
Jay - avatar
1 Answer
+ 5
What does this mean, as in sample code for what purpose? Employer class with a constructor, private or protected members for variables; getters and setters. If that was right then it's best have private members for variables unless a cold class is needed.
24th Feb 2017, 7:45 PM
Mark Foxx
Mark Foxx - avatar