get code to compile and run without exceptions for intellij 13.1.1