First, I read from file. Reading is fine ő
.
Then, I enter ő
in console and if I compare them I got false. I want ő
with console reading as well.
Edit: I use InputStream inp = new FileInputStream(file)
for reading file.
First, I read from file. Reading is fine ő
.
Then, I enter ő
in console and if I compare them I got false. I want ő
with console reading as well.
Edit: I use InputStream inp = new FileInputStream(file)
for reading file.
Try using InputStreamReader(System.in, "ISO-8859-16")
instead.
ISO-8859-15 does not contain the character ő
but ISO-8859-16 does. Furthermore ő
is code point 0151
in ISO-8859-16 which is the same code point as ö
in ISO-8859-15 which explains your current result.