Java tutorial
import java.text.Normalizer; public class Main { public static void main(String args[]) throws Exception { System.out.println(formatString("")); } public static String formatString(String s) { String temp = Normalizer.normalize(s, Normalizer.Form.NFD); return temp.replaceAll("[^\\p{ASCII}]", ""); } }