How to handle input.