{"trustable":false,"sections":[{"title":"","value":{"format":"HTML","content":"\u003cstyle type\u003d\"text/css\"\u003e\r\nh1,h2,h3,h4,h5,h6{margin-bottom:0;}div.textBG p{margin: 0 0 0.0001pt;}\u003c/style\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\tLet \u003cspan class\u003d\"MATH\"\u003e\u003ci\u003eA\u003c/i\u003e\u003c/span\u003e be an \u003c!-- MATH\r\n $N \\times N$\r\n --\u003e\u003cspan class\u003d\"MATH\"\u003e\u003ci\u003eN\u003c/i\u003e\u0026times;\u003ci\u003eN\u003c/i\u003e\u003c/span\u003e matrix of zeros and ones. A \u003cspan data-scayt_word\u003d\"submatrix\" data-scaytid\u003d\"1\"\u003esubmatrix\u003c/span\u003e \u003cspan class\u003d\"MATH\"\u003e\u003ci\u003eS\u003c/i\u003e\u003c/span\u003e of \u003cspan class\u003d\"MATH\"\u003e\u003ci\u003eA\u003c/i\u003e\u003c/span\u003e is any group of \u003cem\u003econtiguous\u003c/em\u003e entries that forms a square or a rectangle.\u003c/p\u003e\r\n\u003cp\u003e\r\n\tWrite a program that determines the number of elements of the largest \u003cspan data-scayt_word\u003d\"submatrix\" data-scaytid\u003d\"2\"\u003esubmatrix\u003c/span\u003e of ones in \u003cspan class\u003d\"MATH\"\u003e\u003ci\u003eA\u003c/i\u003e\u003c/span\u003e. \u003cem\u003eLargest\u003c/em\u003e here is measured by area.\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003ch2\u003e\r\n\t\u003cfont color\u003d\"#0070E8\"\u003e\u003ca name\u003d\"SECTION0001001000000000000000\"\u003e Input\u003c/a\u003e\u0026nbsp;\u003c/font\u003e\u003c/h2\u003e\r\n\u003cp\u003e\r\n\t\u003cb\u003eThe input begins with a single positive integer on a line by itself indicating the number of the cases following, each of them as described below. This line is followed by a blank line, and there is also a blank line between two consecutive inputs. \u003c/b\u003e\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\tThe matrix is given line by line. Each line consists of \u003ctt\u003e0\u003c/tt\u003e\u0026#39;s and \u003ctt\u003e1\u003c/tt\u003e\u0026#39;s. The order of the matrix is also the number of lines input and \u003c!-- MATH\r\n $1 \u003c N \\le 25$\r\n --\u003e\u003cspan class\u003d\"MATH\"\u003e1 \u003cimg align\u003d\"MIDDLE\" alt\u003d\"$ \\le$\" border\u003d\"0\" height\u003d\"30\" src\u003d\"http://uva.onlinejudge.org/external/8/836img1.png\" width\u003d\"18\" /\u003e \u003ci\u003eN\u003c/i\u003e \u003cimg align\u003d\"MIDDLE\" alt\u003d\"$ \\le$\" border\u003d\"0\" height\u003d\"30\" src\u003d\"http://uva.onlinejudge.org/external/8/836img1.png\" width\u003d\"18\" /\u003e 25\u003c/span\u003e.\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003ch2\u003e\r\n\t\u003cfont color\u003d\"#0070E8\"\u003e\u003ca name\u003d\"SECTION0001002000000000000000\"\u003e Output\u003c/a\u003e\u0026nbsp;\u003c/font\u003e\u003c/h2\u003e\r\n\u003cp\u003e\r\n\t\u003cb\u003eFor each test case, the output must follow the description below. The outputs of two consecutive cases will be separated by a blank line. \u003c/b\u003e\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\tThe output is the number of elements of the largest \u003cspan data-scayt_word\u003d\"submatrix\" data-scaytid\u003d\"4\"\u003esubmatrix\u003c/span\u003e found.\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003ch2\u003e\r\n\t\u003cfont color\u003d\"#0070E8\"\u003e\u003ca name\u003d\"SECTION0001003000000000000000\"\u003e Sample Input\u003c/a\u003e\u0026nbsp;\u003c/font\u003e\u003c/h2\u003e\r\n\u003cpre\u003e\r\n1\r\n\r\n10111000\r\n00010100\r\n00111000\r\n00111010\r\n00111111\r\n01011110\r\n01011110\r\n00011110\r\n\u003c/pre\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003ch2\u003e\r\n\t\u003cfont color\u003d\"#0070E8\"\u003e\u003ca name\u003d\"SECTION0001004000000000000000\"\u003e Sample Output\u003c/a\u003e\u0026nbsp;\u003c/font\u003e\u003c/h2\u003e\r\n\u003cpre\u003e\r\n16\r\n\u003c/pre\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cp\u003e\r\n\t\u0026nbsp;\u003c/p\u003e\r\n\u003cbr /\u003e"}}]}