Java project
Project Pentadeca. Thursday April 26 Write a Pentadeca class that encapsulates a Pentadeca number value. THE USE OF ARRAYS IS NOT PERMITTED A Pentadeca number is one with 15 digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E. The methods the class has are: public void readO, publie void set(String), public void set(int), public void set(Pentadeca),public Pentadeca get), public Pentadeca add(Pentadeca), public Pentadeca subtract(Pentadeca), public Pentadeca multiply (Pentadeca), public Pentadeca divide(Pentadeca), public Pentadeca add(int), public Pentadeca subtract(int), public Pentadeca multiply(int), public Pentadeca divide(int), public Pentadeca add(String), public Pentadeca subtract(String), public Pentadeca multiply(String), public Pentadeca divide(String), public boolean equals(Pentadeca), and public String toString). Write private methods to check for valid character input, remove the base p character and set the sign. Your class must consider both positive and negative values. Your class should have at least 3 constructors: a default constructor, an explicit constructor with an integer argument and an explicit constructor with a String argument. I will provide a main program as the demo. Recall the nature of numbers and their construction. 1371 is 1 103 101+7 10 In the same way 1A9is would be 1 152+10 15+15. Given the decimal number 13710 the digits can be determined using the integer operators/ and %. I 37 % 10 gives the 7, 137/ 10 gives l 313% 10 gives 3 and i 3/10 gives 1 . I %10 gives l and 1/10 gives 0. The digits base 10 of 137 are 1, 3,7. The number 13710 converted to base 5 would be l 37905 that gives 2, 137/5 gives 27, 27%) gives 2, 27/5 gives S. Sas gives 0, 515 gives l 1905 gives l and l/5 gives 0. This gives the base 5 number 1022. 13710 converted to base 15 would be 137%) 5 gives 2, 137/15 gives 9. 9%15 gives 9 and 915 gives 0. The number 13710 is therefore 9215