Driver code
public static void main ( String [ ] args ) { int [ ] a = { 5 , 5 , 4 , 3 , 2 , 1 } ; int n = a . length ; System . out . print ( " Minimum ▁ number ▁ of ▁ chocolates ▁ = ▁ " + minChocolates ( a , n ) ) ; }