2 questions I do not have aclue about the 1st one do not know where to start.Second one I attempted but I do not know the code for staying on the first item and checking every other item against it to see if there are any duplicates.So can sum 1 pls help thanks
class ArrayListExtra extends ArrayList
public boolean occursUpTo( Object query, int limit)
//does 'query' occur amongst the first 'limit' items in this 'ArrayListExtra' object?
public void removeDuplicates( )
//remove all duplicate items from this ArrayListExtra object,
//so that it now contains exactly one occurrence of each item
for( int i=0;i<this.size( );i ++)
Re: arraylist help
I could not get what you are asking can you frame your questions a bit in a better way.
|All times are GMT +5.5. The time now is 04:05.|