#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, ans = 0;
  cin >> n;
  string s;
  cin >> s;
  int arr[26];
  for (i = 0; i < 26; i++) arr[i] = 0;
  if (n > 26)
    cout << -1 << endl;
  else {
    for (i = 0; i < n; i++) arr[s[i] - 'a']++;
    for (i = 0; i < 26; i++) {
      if (arr[i] > 1) ans += arr[i] - 1;
    }
    cout << ans << endl;
  }
}
