init working commit, some garbage/tabs
Fixed tabulation
Moved some code into separate func

+ some other small changes.
Merge pull request #3 from danilaml/evolution

Pull request as requested