Adding MVC architecture, and organizing the code more and adding some docs string.

the indentation musth be 2 spaces not 4 spaces.