Driver Code
public static void main ( String args [ ] ) { ArrayList < Integer > a = new ArrayList < Integer > ( ) ; a . add ( 1 ) ; a . add ( - 3 ) ; a . add ( 1 ) ; a . add ( 0 ) ; minOperations ( a ) ; } }