#define _GLIBCXX_DEBUG
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstdarg>
#include <cstdio>
#include <cstring>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <utility>
#include <vector>
using namespace std;

// struct Fast {Fast(){std::cin.tie(0);ios::sync_with_stdio(false);}} fast;

#define mp make_pair
#define pb push_back
#define fi first
#define se second
#define inf 1001001001
#define FOR(i,a,b) for(int (i)=((int)a); (i)<((int)b); (i)++) // [a,b)
#define rep(i,N) FOR((i), 0, ((int)N)) // [0,N)
#define all(v) (v).begin(),(v).end()
#define sz(v) ((int)(v).size())
#define in(t,...) t __VA_ARGS__; _in(__VA_ARGS__)

// デバッグ用
// dbg(...) printfと同様に使用可能 
// trc(var) (変数名)=(値)と表示
// stopif(val) 条件分が真の時に止まる
// vdbg(v) vの中身を表示

#ifdef LOCAL
    #define dbg(...) fprintf(stderr, __VA_ARGS__)
    #define trc(var) cout << #var << "=" << var << endl
    #define stopif(val) assert( !(val) )
    #define vdbg(v,...) cout << #v << "={"; vector_debug(v , ##__VA_ARGS__)
#else
    #define dbg(...) 1
    #define trc(var) 1
    #define stopif(val) 1
    #define vdbg(v) 1
#endif

typedef long long ll;
typedef pair<int,int> pii;
typedef pair<ll,ll> pll;
typedef vector<int> vi;
typedef vector<ll> vl;
typedef vector< vector<int> > vvi;
int gcd(int a, int b){if(a>b) swap(a,b); return a==0 ? b : gcd(b%a,a);}
ll gcd(ll a, ll b){if(a>b) swap(a,b); return a==0 ? b : gcd(b%a,a);}
template<typename T, typename U> inline bool amin(T &x, U y) { return (y < x) ? (x = y, true) : false; }
template<typename T, typename U> inline bool amax(T &x, U y) { return (x < y) ? (x = y, true) : false; }
template<typename C> inline void vin(vector<C> &v,int N){if(sz(v) != 0){rep(i,N) cin >> v[i];}else{C c;rep(i,N) v.pb((cin>>c,c));}}
template<typename C> inline void vin(C v[],int N){rep(i,N) cin >> v[i];}
template<typename C> inline void vector_debug(const vector<C> &v){ostream_iterator<C> o(cout,",");copy(all(v),o);cout<<"}"<<endl;}
template<typename C> inline void vector_debug(C v[], int N){rep(i,N) cout<<*(v+i)<<","; cout<<"}"<<endl;}
template<typename C> inline C vmax(const vector<C> &v){C n=v[0]; rep(i,sz(v)) amax(n,v[i]); return n;}
template<typename C> inline C vmax(C v[], int N){C n=v[0]; rep( i , N ) amax(n,v[i]); return n;}
template<typename C> inline C vmin(const vector<C> &v){C n=v[0]; rep(i,sz(v)) amin(n,v[i]); return n;}
template<typename C> inline C vmin(C v[], int N){C n=v[0]; rep( i , N ) amin(n,v[i]); return n;}
template<typename C> inline C vsum(const vector<C> &v){C n=0; rep(i,sz(v)) n+=v[i]; return n;}
template<typename C> inline C vsum(C v[], int N){C n=0; rep( i , N ) n+=v[i]; return n;}
template<typename C> inline C vsumr(const vector<C> &v,int a,int b){C n=0; FOR(i,a,b) n+=v[i]; return n;}
template<typename C> inline C vsumr(C v[],int a,int b){C n=0; FOR(i,a,b) n+=v[i]; return n;}
void _in(){} template <typename T,class... U> void _in(T &t,U &...u){ cin >> t; _in(u...);}
void out(){cout << endl;} template <typename T,class... U> void out(T const &t,U ...u){ cout << t; if(sizeof...(u)) cout << ' '; out(u...);}

#define mod 1000000007

inline ll madd(ll a, ll b){
    return (a + b) % mod;
}
inline ll msub(ll a, ll b){
    return (a + mod - b) % mod;
}
inline ll mmul(ll a, ll b){
    return ((a % mod) * (b % mod)) % mod;
}
ll mpow(ll a, ll b){
    if(b == 0) return 1;
    else if(b == 1) return a % mod;
    else if(b % 2 == 0){
        ll hlf = mpow(a,b/2);
        return (hlf * hlf) % mod;
    }
    else {
        ll hlf = mpow(a,b/2);
        return ( mmul(hlf , hlf) * a ) % mod;
    }
}
inline ll mdiv(ll a, ll b){
    return mmul(a, mpow(b, mod-2));
}

// in(int,A,B,C) int A,B,C; cin >> A >> B >> C;
// out(A,B,C) cout << A << ' ' <<  B << ' ' << C;
// amax(x,y) bool関数　x<yの時にxにyを代入してtrueを返す
// vin(v) ベクトルにcinする　vin(v,N) 配列にcinする

int main(){
    in(int ,N);
    string s; cin >> s;
    vl v;
    for(int i = 'a';i <= 'z'; i++){
        v.pb(count(all(s),i));
    }
    vdbg(v);
    ll ans = 1;
    rep(i,26){
        if(v[i] == 0) continue;
        ans = mmul(ans,madd(v[i] , 1));
    }
    cout << msub(ans , 1) << endl;
    return 0;
}

Measured memory_bytes: 512