#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 7;
int n, k;
long long dp[2010][2010], sum[2010], ans;
char s[2010];
int main() {
  scanf("%d %d", &n, &k);
  scanf("%s", s + 1);
  dp[0][0] = 1;
  sum[0] = 1;
  for (int i = 1; i <= n; i++) {
    for (int j = 0; j <= k; j++) {
      for (int l = i - 1; l >= 0 && (i - l) * (n - i + 1) <= j; l--) {
        (dp[i][j] += dp[l][j - (i - l) * (n - i + 1)]) %= mod;
      }
      dp[i][j] = dp[i][j] * (long long)('z' - s[i]) % mod;
      (dp[i][j] += (long long)(s[i] - 'a') * sum[j] % mod) %= mod;
      (sum[j] += dp[i][j]) %= mod;
    }
  }
  for (int i = 0; i <= n; i++) {
    (ans += dp[i][k]) %= mod;
  }
  printf("%lld\n", ans);
  return 0;
}
