#include <bits/stdc++.h>

using namespace std;

#define int int64_t
const int MOD = 1e9+7;

int total[26];

signed main() {
	int n, ans = 1;
	
	cin >> n;
	while(n--) {
		char temp;
		cin >> temp;
		total[temp-'a']++;
	}
	
	for(int i = 0; i < 26; i++) ans = (ans * (total[i]+1)) % MOD;
	cout << ((ans-1) + MOD) % MOD;
}