/* package whatever; // don't place package name! */
import java.util.*;
import java.lang.*;
import java.io.*;
/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
{
// echo "тест тест" | iconv -f 'utf-8' -t 'windows-1251' | base64
byte[] decodedBytes = Base64.getDecoder().decode("0YLQtdGB0YIg0YLQtdGB0YIK");
System.
out.
println(new String(decodedBytes,
"windows-1251") + "\n");
final StringBuilder responseString = new StringBuilder();
while ((line = reader.readLine()) != null) {
responseString.append(line);
}
reader.close();
System.
out.
println(responseString.
toString()); }
}
LyogcGFja2FnZSB3aGF0ZXZlcjsgLy8gZG9uJ3QgcGxhY2UgcGFja2FnZSBuYW1lISAqLwoKaW1wb3J0IGphdmEudXRpbC4qOwppbXBvcnQgamF2YS5sYW5nLio7CmltcG9ydCBqYXZhLmlvLio7CgovKiBOYW1lIG9mIHRoZSBjbGFzcyBoYXMgdG8gYmUgIk1haW4iIG9ubHkgaWYgdGhlIGNsYXNzIGlzIHB1YmxpYy4gKi8KY2xhc3MgSWRlb25lCnsKCXB1YmxpYyBzdGF0aWMgdm9pZCBtYWluIChTdHJpbmdbXSBhcmdzKSB0aHJvd3MgamF2YS5sYW5nLkV4Y2VwdGlvbgoJewoJCS8vIGVjaG8gItGC0LXRgdGCINGC0LXRgdGCIiB8IGljb252IC1mICd1dGYtOCcgLXQgJ3dpbmRvd3MtMTI1MScgfCBiYXNlNjQKCQkKCQlieXRlW10gZGVjb2RlZEJ5dGVzID0gQmFzZTY0LmdldERlY29kZXIoKS5kZWNvZGUoIjBZTFF0ZEdCMFlJZzBZTFF0ZEdCMFlJSyIpOwoJCVN5c3RlbS5vdXQucHJpbnRsbihuZXcgU3RyaW5nKGRlY29kZWRCeXRlcykgKyAiXG4iKTsKCQlTeXN0ZW0ub3V0LnByaW50bG4obmV3IFN0cmluZyhkZWNvZGVkQnl0ZXMsICJ3aW5kb3dzLTEyNTEiKSArICJcbiIpOwoJCQoJCQoJCWZpbmFsIFN0cmluZ0J1aWxkZXIgcmVzcG9uc2VT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