Driver program to test above function
public static void Main ( ) { SortWave ob = new SortWave ( ) ; int [ ] arr = { 10 , 90 , 49 , 2 , 1 , 5 , 23 } ; int n = arr . Length ; ob . sortInWave ( arr , n ) ; for ( int i = 0 ; i < n ; i ++ ) Console . Write ( arr [ i ] + " ▁ " ) ; } }