Forse ho capito, intendevi così:

codice:
int c;
		    Random rand=new Random();
			for(int i=1;i<x.length;i++){
				for(int j=0;j<x[0].length;j++){
					c=rand.nextInt(((b)contenitore[j]).getNumber());
					x[i][j]=(((b)contenitore[j]).getValue(c));
					
					}
					
				}