Separated Classes

Separated classes in the main project.
Easier to maintain with modularization.

Added thorough test cases.
refractored

Made changes to test cases.
Moved from test folder to src folder for test project.