示例#1
0
 public CellSeed[] GetRowSeed(int index)
 {
     CellSeed[] row = new CellSeed[_size];
     for (int i = 0; i < _size; i++)
     {
         row[i] = Seed[index, i];
     }
     return(row);
 }
示例#2
0
 public CellSeed[] GetColumnSeed(int index)
 {
     CellSeed[] col = new CellSeed[_size];
     for (int i = 0; i < _size; i++)
     {
         col[i] = Seed[i, index];
     }
     return(col);
 }
示例#3
0
            public MatrixSeed(int size)
            {
                this._size = size;
                this.Seed  = new CellSeed[size, size];
                var seed = Enumerable.Range(1, size);

                for (int i = 0; i < size; i++)
                {
                    for (int j = 0; j < size; j++)
                    {
                        Seed[i, j] = new CellSeed(seed, new Skyscrapers5.Index(i, j));
                    }
                }
            }