我有一个字符串名称 s,
String s = "<NOUN>Sam</NOUN> , a student of the University of oxford , won the Ethugalpura International Rating Chess Tournament which concluded on Dec.22 at the Blue Olympiad Hotel";
我想从字符串中删除所有 < NOUN > 和 < /NOUN > 标记。我用它来删除标签,
s.replaceAll("[<NOUN>,</NOUN>]","");
是的,它删除了标签。但它也会从字符串中删除字母 'U' 和 'O' 字符,这给了我以下输出。
Sam , a student of the niversity of oxford , won the Ethugalpura International Rating Chess Tournament which concluded on Dec.22 at the Blue lympiad Hotel
谁能告诉我如何正确地做到这一点?