Quote (Acdc-rocks[tom] @ Feb 11 2014 07:34pm)
im trying to trade the white space for a , so my output looks like [1,2,3,4] rather than [1 2 3 4]
ok, so your list is fine and you're just complaining about toString(). two ways to handle it.
1) as i described earlier, create your own function to do it precisely the way you want
2) more of a hack, but you can do something like this: System.out.println(list.toString().replace(' ', ','));
i don't remember the method signature, but essentially you wanna call toString() yourself then replace space with comma before printing it.