Driver code
static public void Main ( ) { int [ ] Arr = { 3 , 2 , 1 , 1 , 4 } ; int N = Arr . Length ; if ( checkIndices ( Arr , N ) ) Console . WriteLine ( " Yes " ) ; else Console . WriteLine ( " No " ) ; } }