Implemented mode selection
Merge pull request #52 from vanityset/master

Implemented mode selection