read user input using scanner