Meaningless Drivel is fun!*
The moose likes Beginning Java and the fly likes array of arrays with arraylist Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic
Author

array of arrays with arraylist

vijayapriya thirumurugan
Greenhorn

Joined: Apr 03, 2009
Posts: 16

Hello sir,

How ever i want to knnow how to store arraylist in two dimension array(Array of arrays).

My problem is:

I have 100000 row of data. i want to store the row number which is corresponding to the element store in the two dimension array.
Let me say that i have array of array called array[n][n]. I want to store the row number of the number 2 in the arraylist which is corresponding to the a array of array index array[2][2]. Like this this i should store 1000 elements, i.e., array[1][1],array[2][2],.....array[1000][1000].



K. Tsang
Bartender

Joined: Sep 13, 2007
Posts: 2247
    
    7

Ok given you have:

How do you convert this into arraylist? Would it be better to keep it as a 2D array? Can you simplify your data to use collections like arraylist or vector or even maps etc?

What do you need to store in the first place disregarding the record/row number?


K. Tsang JavaRanch SCJP5 SCJD/OCM-JD OCPJP7 OCPWCD5
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38075
    
  22
Closing as duplicate of this thread.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: array of arrays with arraylist
 
Similar Threads
multi dimension array
An object to hold several arrays
arrays with arraylist
How to transpose a matrix?
two dimension array