#include <bits/stdc++.h>
int a[10001];
int main() {
  char b[100001];
  int k, m, max = 0, min = 130, cnt = 0, n, co = 0;
  scanf("%d", &n);
  scanf("%s", b);
  m = strlen(b);
  for (k = 0; k < m; k++) {
    a[b[k]]++;
    if (b[k] > max) max = b[k];
    if (min > b[k]) min = b[k];
  }
  for (k = min; k <= max; k++) {
    if (a[k]) {
      cnt = cnt + a[k] - 1;
      co++;
    }
  }
  if (co + cnt > 26) cnt = -1;
  printf("%d", cnt);
  return 0;
}
