日期:2014-05-20 浏览次数:20610 次
string.split(",");
------解决方案--------------------
public class Test { public static void main(String[] args) { String str = "B1,B2,B3,B4,B5"; Object[] o = str.split(","); for(int i = 0;i < o.length;i++) { System.out.println(o[i]); } } }
------解决方案--------------------
String[] a="B1,B2,B3,B4,B5".split(",")