Create formatted string from ArrayList

前端 未结 7 876
隐瞒了意图╮
隐瞒了意图╮ 2021-01-04 20:11

Consider following code:

    ArrayList aList = new ArrayList();
    aList.add(2134);
    aList.add(3423);
    aList.add(4234);
         


        
7条回答
  •  醉梦人生
    2021-01-04 21:03

    You will have to replace the last comma with a ')'. But use a StringBuilder instead of adding strings together.

提交回复
热议问题