I am trying to write an exception to throw, for an invalid testScore array. If the scores are greater than 100 or less than one. I attached the three classes I have created. I also have to return the average.... If anyone can help I would appreciate it. I am getting an error in the demo class.

Recommended Answers

All 3 Replies

If anyone can help I would appreciate it. I am getting an error in the demo class.

isn't that the whole point of throwing Exceptions? :)
could you paste the code here, instead of attaching the files? It'll make it a lot easier for us to read it

Yes, I know that but what I meant is that the demo class does not run... Im not sure as to what I did wrong...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.