out of range error handling