for loops to stream and other refactor
Variable renamed
Merge pull request #31 from Laastine/java-refactor

Java refactor