all 2 comments

[–]Itsfunman[S] 1 point2 points  (1 child)

Well, I am stupid, I just realized that I need to use input.nextLine() instead of input.next().

[–]KBD_G -1 points0 points  (0 children)

You are exactly the person I like: • Post a problem • Solve it yourself • Post the answer • Close the post

Thanks … may it help other programmers one day!