#include <bits/stdc++.h>
const int N = 2005;
const int mod = 1e9 + 7;
using namespace std;
int n, k, dp[N][N], sum[N][N], ans;
string s;
void add(int& a, int b) {
  a += b;
  if (a >= mod) a -= mod;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> k;
  cin >> s;
  s = '.' + s;
  dp[0][0] = 1;
  sum[0][0] = 1;
  for (int i = 1; i <= n; i++) {
    for (int j = 0; j <= k; j++) {
      dp[i][j] = 1LL * sum[i - 1][j] * (s[i] - 'a') % mod;
      for (int x = 1; x * (n - i + 1) <= j && x <= i; x++) {
        add(dp[i][j],
            1LL * dp[i - x][j - x * (n - i + 1)] * ('z' - s[i]) % mod);
      }
      if (i < n) sum[i][j] = (sum[i - 1][j] + dp[i][j]) % mod;
    }
    add(ans, dp[i][k]);
  }
  cout << ans + (k == 0);
}
