refactoring + new console app