Function to count minimum number of operations required
const n = 3 ; const m = 3 ; function countDecrements ( arr ) { let count_1 = 0 ; let count_2 = 0 ; for ( let i = 0 ; i < n ; i ++ ) { for ( let j = 0 ; j < m ; j ++ ) {