Why will I have an empty string if I execute this program in Java?

前端 未结 0 1933
青春惊慌失措
青春惊慌失措 2021-01-17 07:37

Here is the code:

Scanner input = new Scanner(System.in);
int val = input.nextInt();
String value = input.nextLine();
// Program continues from here


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题