Exemplo n.º 1
0
        private void button4_Click(object sender, EventArgs e)
        {
            Random rand = new Random();

            if (_rowCount <= 0)
            {
                _rowCount = rand.Next(1, 10);
                array     = new CustomDoubleArray[_rowCount];
            }

            if (_cellCount <= 0)
            {
                _cellCount = rand.Next(1, 10);
                for (int i = 0; i < array.Length; i++)
                {
                    array[i]     = new CustomDoubleArray();
                    array[i].Arr = new double[_cellCount];
                }
            }

            for (int i = 0; i < array.Length; i++)
            {
                for (int j = 0; j < array[i].Arr.Length; j++)
                {
                    array[i].Arr[j] = (double)rand.Next(-4000, 4000) / 100;
                }
            }
            Print(array, Array2Holder, "");
        }
Exemplo n.º 2
0
 private void buttonSubmit_Click(object sender, EventArgs e)
 {
     array = new CustomDoubleArray[_rowCount];
     for (int i = 0; i < array.Length; i++)
     {
         array[i] = new CustomDoubleArray();
     }
 }