Problem 228

Encapsulate!

Required files:

Modify the included file by providing the class with a constructor method and proper encapsulation. I have added the JavaDoc for all required methods.

Checklist:

  1. Constructor
  2. Getters for age and name.
  3. Setters for age and name.

Try to run the test file, first, by commenting out all the tests. Then, un-comment them one by one once you get them to pass.


◄ 227: Encapsulation