CF375B Maximum Submatrix 2

Description

You are given a matrix consisting of digits zero and one, its size is $ n×m $ . You are allowed to rearrange its rows. What is the maximum area of the submatrix that only consists of ones and can be obtained in the given problem by the described operations? Let's assume that the rows of matrix $ a $ are numbered from 1 to $ n $ from top to bottom and the columns are numbered from 1 to $ m $ from left to right. A matrix cell on the intersection of the $ i $ -th row and the $ j $ -th column can be represented as $ (i,j) $ . Formally, a submatrix of matrix $ a $ is a group of four integers $ d,u,l,r $ $ (1

Input Format

N/A

Output Format

N/A