Java substring: ‘string index out of range’ by IT Nursery Java substring: ‘string index out of range’