added comments
Added input prompt in input_loop()