Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1.Write a class with a static method that accepts a string, displays the number

ID: 3533735 • Letter: 1

Question

1.Write a class with a static method that accepts a string, displays the number of characters, and throws an

exception if any character in the string is not in the set {'a'..'z', '0'..'9', 'A'..'Z'}. The exception should be

thrown but not caught (i.e., no explicit catch block). Write a client program that calls this method and prints

"Error in Input" if the method throws an exception..      



2.Design a class named Triangle that extends GeometricObject (corresponding to UML shown

below). The class contains:

Explanation / Answer

are you using java or another program?