read input from stdin