Driver code
public static void main ( String [ ] args ) { int [ ] [ ] mat = new int [ ] [ ] { { 1 , 0 , 0 , 1 } , { 0 , 1 , 1 , 1 } , { 1 , 0 , 0 , 0 } , { 0 , 1 , 0 , 1 } } ; int n = 4 ; largestSubmatrix ( mat , n ) ; } }