save the last input