Update AntWorld.java

worked on checkSyntax method