我试着想出一个正则表达式来解决这个问题,但是没有结果。下面是一些我需要的例子。[]将数组表示为输出。Hello $World[$World]My name is $John Smith and I like $pancakes[$John, $pancakes]String test = "My name $is John $Smith";System.out.println(te
我正在尝试拆分一个字符串数组,其中每个字符串都有",“作为分隔符。在之前使用regex对新行模式进行拆分之后,我获得了字符串数组。输入来自文本文件,这是与文本文件一样的模式。StreamReader sr = new stream reader(file.txt);String pattern = @"\r\n";
String[] result = regex.split(da