#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
int dp[55][1300];
struct Box {
  int pos;
  int num;
  char color;
} box[55];
bool operator<(Box a, Box b) { return a.num < b.num; }
int main() {
  ios::sync_with_stdio(false);
  int n, s, k;
  while (cin >> n >> s >> k) {
    for (int i = 0; i <= n; i++)
      for (int j = 0; j <= 1300; j++) dp[i][j] = INF;
    for (int i = 1; i <= n; i++) {
      box[i].pos = i;
    }
    for (int i = 1; i <= n; i++) {
      cin >> box[i].num;
    }
    for (int i = 1; i <= n; i++) {
      cin >> box[i].color;
    }
    sort(box, box + n + 1);
    box[0].pos = s;
    dp[0][0] = 0;
    for (int i = 0; i <= n; i++) {
      for (int j = 0; j <= 1300; j++) {
        if (dp[i][j] == INF) continue;
        for (int k = i + 1; k <= n; k++) {
          if (box[k].num <= box[i].num || box[k].color == box[i].color)
            continue;
          dp[k][j + box[k].num] = min(dp[k][j + box[k].num],
                                      dp[i][j] + abs(box[k].pos - box[i].pos));
        }
      }
    }
    int ans = INF;
    for (int i = 1; i <= n; i++) {
      for (int j = k; j <= 1300; j++) {
        ans = min(ans, dp[i][j]);
      }
    }
    cout << (ans == INF ? -1 : ans) << endl;
  }
}
