Implemented basic input function and tested for the three test cases

Please use the unittest framework - https://docs.python.org/2/library/unittest.html - to write your tests. Essentially, you will asserts within the code rather than print statements to verify the output of a function is as expected. It will also make the tests automatable.