how to remove Punctuation in word in java code example Example: java remove punctuation from string inputString.replaceAll("\\p{Punct}", "");