예제 #1
0
        public void MaximalRectangleTest_OneRow()
        {
            var input = new char[1][]
            {
                new char[] { '1', '1', '1' }
            };

            var solution = new _085_MaximalRectangle();
            var result   = solution.MaximalRectangle(input);

            Assert.AreEqual(3, result);
        }
예제 #2
0
        public void MaximalRectangleTest_OneItem()
        {
            var input = new char[1, 1]
            {
                { '1' }
            };

            var solution = new _085_MaximalRectangle();
            var result   = solution.MaximalRectangle(input);

            Assert.AreEqual(1, result);
        }
예제 #3
0
        public void MaximalRectangleTest_OneItem_Zero()
        {
            var input = new char[1][]
            {
                new char[] { '0' }
            };

            var solution = new _085_MaximalRectangle();
            var result   = solution.MaximalRectangle(input);

            Assert.AreEqual(0, result);
        }
예제 #4
0
        public void MaximalRectangleTest_OneItem_Zero()
        {
            var input = new char[1, 1]
            {
                { '0' }
            };

            var solution = new _085_MaximalRectangle();
            var result = solution.MaximalRectangle(input);

            Assert.AreEqual(0, result);
        }
예제 #5
0
        public void MaximalRectangleTest_3()
        {
            var input = new char[2][]
            {
                new char[] { '1', '0' },
                new char[] { '1', '0' }
            };

            var solution = new _085_MaximalRectangle();
            var result   = solution.MaximalRectangle(input);

            Assert.AreEqual(2, result);
        }
예제 #6
0
        public void MaximalRectangleTest_3()
        {
            var input = new char[2, 2]
            {
                { '1', '0' },
                { '1', '0' }
            };

            var solution = new _085_MaximalRectangle();
            var result = solution.MaximalRectangle(input);

            Assert.AreEqual(2, result);
        }
예제 #7
0
        public void MaximalRectangleTest()
        {
            var input = new char[3, 3]
            {
                { '1', '1', '1' },
                { '1', '0', '1' },
                { '1', '1', '1' }
            };

            var solution = new _085_MaximalRectangle();
            var result   = solution.MaximalRectangle(input);

            Assert.AreEqual(3, result);
        }
예제 #8
0
        public void MaximalRectangleTest_OneRow()
        {
            var input = new char[1, 3]
            {
                { '1', '1', '1' }
            };

            var solution = new _085_MaximalRectangle();
            var result = solution.MaximalRectangle(input);

            Assert.AreEqual(3, result);
        }