Esempio n. 1
0
        public DPTable GetTable()
        {
            int     n      = _building.FloorNum();
            int     m      = _iphone.Num();
            DPTable _table = new DPTable(_building.FloorNum(), _iphone.Num());
            int     i;

            for (i = 1; i < n + 1; i++)
            {
                _table[i, 1] = i;
            }
            for (i = 1; i < m + 1; i++)
            {
                _table[1, i] = 1;
            }
            return(_table);
        }
Esempio n. 2
0
        public DPTable CreateMargin(DPTable table)
        {
            int n = _building.FloorNum();
            int m = _iphone.Num();

            table._table = new int[n + 1, m + 1];
            int i;

            for (i = 1; i < n + 1; i++)
            {
                table._table[i, 1] = i;
            }
            for (i = 1; i < m + 1; i++)
            {
                table._table[1, i] = 1;
            }
            return(table);
        }