Exercise 1b Write a class named Friend to represent one of your friends. Please note that you should not include the dat
Posted: Fri Jul 01, 2022 5:39 am
Exercise 1b Write a class named Friend to represent one of your friends. Please note that you should not include the dateOfBirth attribute yet, as you need the Date class to be written. a. Write a constructor to create the Friend with their basic information (just their name) b. Write a method to validate that the phone number is at least 8 digits long (hint... if you divide an integer of less than 8 digits by 100,000,000 then the result is always less than 1) c. Write mutator methods for each of the other friend details. The phone number mutator should utilise the validator method from part b. d. Write accessor methods to return the friend's details