A recursive function to replace previous value ' prevV ' at ' ( x , ▁ y ) ' and all surrounding values of ( x , y ) with new value ' newV ' .
void floodFillUtil ( char mat [ ] [ N ] , int x , int y , char prevV , char newV ) {