CS extras next Thursday: EF, AHD, ZW and more on MIST.
Men's soccer, Saturday at some time.
Participate in #GrinWell.
Friends of Drake Library needs help setting up for their annual booksale
on Thursday, October 2 (conveniently, the same night as Grinnell High
School's homecoming parade). You can help a good cause and probably get
a few free books, too.
When things go wrong
Things go wrong in programs. You get bad input. Files you expect to
be there aren't there. Clients don't pay attention to preconditions.
Two wrong approaches:
Crash the program
Report the error to the user
A correct approach
Report the error to the caller
In Java, we report errors to callers with exceptions
Indicate that a procedure may fail with throws Exception
Indicate that a procedure fails with throw Exception