text: Driver Code
code: public static void Main ( string [ ] args ) { int [ ] arr = { 5 , 3 , 7 , 2 , 1 } ; int X = 10 , Y = 2 ; int N = arr . Length ; Console . WriteLine ( minimumCost ( arr , N , X , Y ) ) ; } }