views:

63

answers:

1

So, now I've figured out how to make multiple of the same object correctly, I need to know how to make an array of them, changing depending on how many are needed, because it is pretty much an object, that stores 3 numbers. How can I Create an arraylist that is of different objects, because I'm going to have the numbers inside them different

+3  A: 
ArrayList<Matrices> list = new ArrayList<Matrices>();
list.add( new Matrices(1,1,10) );
list.add( new Matrices(1,2,20) );
Aaron Saunders
thanks, I cant believe how obvious that was. Its been a while since I've had to mess with ArrayLists
Samuel