¥The operations getFirst() and getRest() are included in the abstract
class IntList because they are useful operations
for clients of IntList.
¥Invoking getFirst() or getRest() on the Empty list is a run-time error, which
we implement by throwing an exception. The Java throw construct takes an object of type Exception (which is a built-in class). In the absence of a catch handler attached to a method on the
call stack, throwing an exception aborts the
computation and prints the String message embedded
in the exception.