#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, p, count = 0, k;
  string s;
  cin >> n >> p >> s;
  if (p > n / 2) p = n - p + 1;
  int l = p - 1, r = p - 1;
  for (int i = 0; i < n / 2; i++) {
    if (s[i] != s[n - i - 1]) {
      l = min(l, i);
      r = max(r, i);
    }
  }
  p--;
  if (p - l > r - p)
    count += (r - p) * 2 + p - l;
  else
    count += (p - l) * 2 + r - p;
  for (int i = l; i <= r; i++) {
    if (s[i] != s[n - 1 - i]) {
      k = abs((int)(s[i] - s[n - i - 1]));
      if (k > 13) k = 26 - k;
      count += k;
    }
  }
  cout << count;
}
