#include <bits/stdc++.h>
using namespace std;
int n, k;
char s[2003];
long long mod = 1e9 + 7, f[2003][2003], sum[2003];
void DP() {
  f[0][0] = sum[0] = 1;
  for (int i = 1; i <= n; ++i) {
    for (int j = 0; j <= k; ++j) {
      f[i][j] = (((sum[j]) * (s[i] - 'a')) % mod);
      for (int z = i - 1; z >= 0; --z) {
        if (j < (i - z) * (n - i + 1)) break;
        f[i][j] = ((f[i][j] +
                    (26 - (s[i] - 'a' + 1)) * f[z][j - (i - z) * (n - i + 1)]) %
                   mod);
      }
      sum[j] = ((sum[j] + f[i][j]) % mod);
    }
  }
  long long res = 0;
  for (int i = 0; i <= n; ++i) res = ((res + f[i][k]) % mod);
  cout << res;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> k;
  for (int i = 1; i <= n; ++i) cin >> s[i];
  DP();
  return 0;
}
