Refactoring Groovy benchmark

Using interfaces instead of implementation for variable declaration and refactoring main method.