1 2 3 4 5 6 7 8 9 10 11 12 13 14 | import java.util.regex.*; class Main { public static void main (String[] args) throws java.lang.Exception { String s = "a1, a2, a3, \"a4,a5\", a6"; Pattern pattern = Pattern.compile("\\s*(\"[^\"]*\"|[^,]*)\\s*"); Matcher matcher = pattern.matcher(s); while (matcher.find()) { System.out.println(matcher.group(1)); } } } |
-
upload with new input
-
result: Success time: 0.06s memory: 380224 kB returned value: 0
a1, "a2,a3", a4, "a5,a6"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.06s memory: 380224 kB returned value: 0
'a','bc "d',edf
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380160 kB returned value: 0
1,2,3,5,"6,7"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380224 kB returned value: 0
import java.util.regex.*; class Main { public static void main (String[] args) throws java.lang.Exception { String s = "a1, a2, a3, \"aaabb\", a6"; Pattern pattern = Pattern.compile("\\s*(\"[^\"]*\"|[^,]*)\\s*"); Matcher matcher = pattern.matcher(s); while (matcher.find()) { System.out.println(matcher.group(1)); } } }a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.06s memory: 380224 kB returned value: 0
import java.util.regex.*; class Main { public static void main (String[] args) throws java.lang.Exception { String s = "a1, a2, a3, \"a4,a5\", a6"; Pattern pattern = Pattern.compile("\\s*(\"[^\"]*\"|[^,]*)\\s*"); Matcher matcher = pattern.matcher(s); while (matcher.find()) { System.out.println(matcher.group(1)); } } }a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.06s memory: 380224 kB returned value: 0
import java.util.regex.*; class Main { public static void main (String[] args) throws java.lang.Exception { String s = "a1, a2, a3, \"a4a5\", a6"; Pattern pattern = Pattern.compile("\\s*(\"[^\"]*\"|[^,]*)\\s*"); Matcher matcher = pattern.matcher(s); while (matcher.find()) { System.out.println(matcher.group(1)); } } }a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380224 kB returned value: 0
import java.util.regex.*; class Main { public static void main (String[] args) throws java.lang.Exception { String s = "a1, a2, a3, \"a4,a5\", a6"; Pattern pattern = Pattern.compile("\\s*(\"[^\"]*\"|[^,]*)\\s*"); Matcher matcher = pattern.matcher(s); while (matcher.find()) { System.out.println(matcher.group(1)); } } }a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380224 kB returned value: 0
"1.000,3","1,3,","2,45","3.333,45","23"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380224 kB returned value: 0
"1.000,3","second,","thi,rd","hello""world"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.06s memory: 380224 kB returned value: 0
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.06s memory: 380224 kB returned value: 0
first,"second,","thi,rd","hello""world"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380160 kB returned value: 0
"colX","12/3/2000","1/20/2001","False",,,"1/22/2001","1.000","0","0",,,,,,"","Normal","False","colX",,"Normal","Complete"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.08s memory: 380160 kB returned value: 0
http://www.boozallen.com/,2/28/2013 18:29,48370608,Yes
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380160 kB returned value: 0
http://www.boozallen.com/,2/28/2013 18:29,48370608,Yes
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.07s memory: 380224 kB returned value: 0
"abc","as,xd","kl"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.02s memory: 245632 kB returned value: 0
"abc","as,xd","kl"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.03s memory: 245632 kB returned value: 0
nc,71881610,?,"Tuesday, November 13, 2012 09:51:07 UTC",38.7893,-122.764,0.6,2.2,?,"5km SW of Cobb, California"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.02s memory: 245632 kB returned value: 0
nc,71881610,?,"Tuesday, November 13, 2012 09:51:07 UTC",38.7893,-122.764,0.6,2.2,?,"5km SW of Cobb, California"
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.03s memory: 245632 kB returned value: 0
10/12/2012,"""Storage""","""964c283a-83a3-4dd4-8baf-59511998fe8b""",,"""Storage Transactions (in 10,000s)""",,0.12740000,"""East Asia""","""Storage""","""mt11696""",,,
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.03s memory: 245632 kB returned value: 0
10;;59;LP;OF;;"3;4;5";1;EF;NA;1;;2;;5;MA;;Euros;1;99320;2012;;;;332AKITAILCANO;X;;;1
a1 a2 a3 "a4,a5" a6
-
result: Success time: 0.05s memory: 213312 kB returned value: 0
a1 a2 a3 "a4,a5" a6


