func_code_string: #include <bits/stdc++.h>   using namespace std;   constexpr int INF = 2e9;   int main() {     int t;     t = 1;     while (t--) {       int n;       string s;       cin >> n;       cin >> s;       int res = 0;       for (int d = 25; d >= 0; d--) {         string tmp =   ;         for (int i = 0; i < s.size(); i++) {           int now = s[i] -  a ;           if (now != d) {             tmp += s[i];           } else {             if (tmp.back() -  a  == d - 1) {               res++;             } else {               tmp += s[i];             }           }         }         swap(s, tmp);         tmp =   ;         for (int i = s.size() - 1; i >= 0; i--) {           int now = s[i] -  a ;           if (now != d) {             tmp += s[i];           } else {             if (tmp.back() -  a  == d - 1) {               res++;             } else {               tmp += s[i];             }           }         }         reverse(tmp.begin(), tmp.end());         swap(s, tmp);       }       cout << res << endl;     }     return 0;   }   