Program reads a list of domains from a text-file and check via Regex if the domain is valid. The problem is that there is some kind of strange whitespace at the end of some domains, which I can't delete. The parsing problems occurs only when there is this strange whitespace. My Regex is totally fine(!!! :-)
I tried trim()
and replaceAll("\\s", "")
both can't work. How can I figure out what kind of strange Char that could be?
Thanks!