+ 1
Can anyone help me out why throws java. io.IOException for getting a character input from user is not working in sololearn
Getting user input single character
2 Antworten
+ 5
Try 'InputMismatchException' once.
Or next idea is :
Scanner sc = new Scanner(System.in);
System.out.println(
sc.nextLine().charAt(0)
);
+ 1
Thank you. I will try.