Formatting fixes & maven

I've fixed a few formatting issues for the lists and code towards the end to make it easier to read. I also had to explicitly set the java version in the pom to support generics, without that the maven build failed.