And there should be a space after while:  ```while (i.hasNext()) {```

http://www.oracle.com/technetwork/java/javase/documentation/codeconventions-142311.html#460