Driver code
int main ( int argc , char const * argv [ ] ) { int arr [ ] = { 1 , 2 , 2 , 3 , 2 , 3 , 4 } ; int n = sizeof ( arr ) / sizeof ( arr [ 0 ] ) ; int k = 2 ; RemoveElements ( arr , n , k ) ; return 0 ; }