I have this code:
String str;
Scanner Lectura = new Scanner(System.in);
System.out.print("Type a word in plain form: ");
str=Lectura.next();
//obtains word
String substring = str.length() > 2 ? str.substring(str.length() - 2) : str;
System.out.print(substring);
...to get the last two digits of a word. I intent to use it with japanese verbs, but for some reason it just returns question marks:
https://i.stack.imgur.com/3e7C2.png
I typed in 食べる which should return べる; the last two characters. Here's proof it's not a unicode problem or something (the console font is so small):
https://i.stack.imgur.com/dTHEz.png
What's the problem? What can I do to get those characters and not question marks?