Changed receiving problem data in Solve method and some cosmetic refactoring