import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class Main {
public static void main
(String[] args
) { String s
= "明昏昐"; Pattern p = Pattern.compile("&#([0-9]+);");
Matcher m = p.matcher(s);
while (m.find()) {
m.appendReplacement(b, "");
b.
append((char) Integer.
parseInt(m.
group(1))); }
m.appendTail(b);
s = b.toString();
s = "あいう";
for (int i = 0; i < s.length(); i++) {
b.append("&#" + (int) s.charAt(i) + ";");
}
s = b.toString();
}
}
aW1wb3J0IGphdmEudXRpbC5yZWdleC5NYXRjaGVyOwppbXBvcnQgamF2YS51dGlsLnJlZ2V4LlBhdHRlcm47CgpwdWJsaWMgY2xhc3MgTWFpbiB7CiAgICBwdWJsaWMgc3RhdGljIHZvaWQgbWFpbihTdHJpbmdbXSBhcmdzKSB7CglTdHJpbmcgcyA9ICImIzI2MTI2OyYjMjYxMjc7JiMyNjEyODsiOwoJUGF0dGVybiBwID0gUGF0dGVybi5jb21waWxlKCImIyhbMC05XSspOyIpOwoJTWF0Y2hlciBtID0gcC5tYXRjaGVyKHMpOwoJU3RyaW5nQnVmZmVyIGIgPSBuZXcgU3RyaW5nQnVmZmVyKCk7Cgl3aGlsZSAobS5maW5kKCkpIHsKCSAgICBtLmFwcGVuZFJlcGxhY2VtZW50KGIsICIiKTsKCSAgICBiLmFwcGVuZCgoY2hhcikgSW50ZWdlci5wYXJzZUludChtLmdyb3VwKDEpKSk7Cgl9CgltLmFwcGVuZFRhaWwoYik7CglzID0gYi50b1N0cmluZygpOwoJU3lzdGVtLm91dC5wcmludGxuKHMpOwoKCXMgPSAi44GC44GE44GGIjsKCWIgPSBuZXcgU3RyaW5nQnVmZmVyKCk7Cglmb3IgKGludCBpID0gMDsgaSA8IHMubGVuZ3RoKCk7IGkrKykgewoJICAgIGIuYXBwZW5kKCImIyIgKyAoaW50KSBzLmNoYXJBdChpKSArICI7Iik7Cgl9CglzID0gYi50b1N0cmluZygpOwoJU3lzdGVtLm91dC5wcmludGxuKHMpOwogICAgfQp9