Hi everyone,
Noticed an interesting behavior of Arrays.asList(T[]) ,method:
Now i have read in K&B that both this array and list refer to the same data, and changes made to the list will reflect in the array.
But when i try to run this code i get an java.lang.UnsupportedOperationException in line1, as well as line2 (if line1 is commented).
Does anyone know what are the other restrictions on the list?
I found an explanation to this at this blog.
So whats the point of getting an array asList ?
-Meher