J
Jeremy Watts
i have created a one-dimensional array of type 'List' , ie. each of the
elements of the array is a list (of integers). The lines i used to do this
being :-
List[] termNumbersArray;
List<Object>termNumbers = new ArrayList<Object>();
.. .
..
.. .
..
then i attempt to add an element (numberOfTerms) to the list at position
'index' with the line :-
termNumbersArray[index].add(numberOfTerms);
It compiles correctly but gives a compiler warning "uses unchecked or unsafe
operations. Note:Recompile with -Xlint:unchecked for details."
How do I get around this?
Thanks
elements of the array is a list (of integers). The lines i used to do this
being :-
List[] termNumbersArray;
List<Object>termNumbers = new ArrayList<Object>();
.. .
..
.. .
..
then i attempt to add an element (numberOfTerms) to the list at position
'index' with the line :-
termNumbersArray[index].add(numberOfTerms);
It compiles correctly but gives a compiler warning "uses unchecked or unsafe
operations. Note:Recompile with -Xlint:unchecked for details."
How do I get around this?
Thanks