making to code a bit more cleaner and setup main class