Scanner modified to work with Mini-Java