added switch case and scanf snippet
Merge pull request #44 from daniel614/patch-1

added switch case and scanf snippet