#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  string s;
  cin >> n;
  cin >> s;
  int alph[26];
  if (n > 26) {
    cout << -1;
    return 0;
  }
  for (int i = 0; i < 26; ++i) {
    alph[i] = 0;
  }
  for (int i = 0; i < n; ++i) {
    alph[s[i] - 'a']++;
  }
  int diff = 0;
  for (int i = 0; i < 26; ++i) {
    if (alph[i]) diff++;
  }
  cout << n - diff << "\n";
  return 0;
}
