programming assignment functions
Merge https://github.com/anshul9212/ProgrammingAssignment2