Instead of "enlarging" an array (making a new array that's bigger, and then moving each element over), you should really consider an ArrayList. You might think of an ArrayList as an array that automatically re-sizes itself.
I know that you've asked about ArrayLists in another thread, so I'm curious why you're using an array. Are you required to use an array here? Do you have more questions about using an ArrayList?
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer sscce.org
@Campbell Ritchie... I took care of this using this(see code):
but thanx anyway.
@marc weber.... thanks for the ArrayList explanation. This is exactly what i was looking for, that notwithstanding i think solving the problem "manually" with Arrays first will help me understand the solution with ArrayLists better(dont u think?)....
@Michael Dunn.... wonderful!...you really helped me there.