Else increment start Also checkin for X at start position
else { if ( s [ start ] == X ) s [ start ] = Y ; start ++ ; } } while ( s . size ( ) > 0 && s [ s . size ( ) - 1 ] == Z ) { s . pop_back ( ) ; } }