func_code_string: #include <bits/stdc++.h>   using namespace std;   int n, s, K, r[55], f[55][2555];   char col[55];   pair<int, int> p[55];   inline void Umn(int &x, int y) { x = min(x, y); }   int main() {     scanf( %d%d%d , &n, &s, &K);     for (int i = 1; i <= n; ++i) scanf( %d , &r[i]);     scanf( %s , col + 1), col[0] =  & ;     for (int i = 1; i <= n; ++i) p[i] = (pair<int, int>){r[i], i};     sort(p + 1, p + n + 1);     memset(f, 0x3f, sizeof f);     f[0][0] = 0;     p[0].second = s;     int ans = 1e9;     for (int i = 1; i <= n; ++i) {       for (int j = p[i].first; j <= 2500; ++j) {         for (int k = 0; k < i; ++k)           if (p[k].first < p[i].first &&               (k == 0 || col[p[k].second] != col[p[i].second]))             Umn(f[i][j], f[k][j - p[i].first] + abs(p[i].second - p[k].second));         if (j >= K) Umn(ans, f[i][j]);       }     }     if (ans > 1e8) return puts( -1 ), 0;     cout << ans << endl;   }   