The second way isn't valid XML; did you mean
If so, then the first one is preferred because all you need to get the array elements is some XML manipulation. On the second one you first need to get the value of the <numbers> element via XML manipulation, then somehow parse the
[3,2,1] text using something else.
Or if you really want some compact format, you can consider using JSON (which "natively" supports arrays). But that depends on your application requirements.
~ Answered on 2011-05-23 14:58:44