Java · Exceptions, files and recursion

try and catch

A user who types x where a number belongs shouldn't crash the whole program: catching the exception lets it carry on.