#include using namespace std ; #define pb push_back #define mp make_pair #define infile() freopen("large.in","r",stdin); #define output() freopen("output.txt","w",stdout); #define ll long long #define sc(t); scanf("%d",&t); #define scl(t); scanf("%lld",&t); #define sc2(n,m); scanf("%d%d",&n,&m); #define scl2(n,m); scanf("%lld%lld",&n,&m); #define debug(); printf("tushar\n"); #define N 105 #define mod 1000000007 #define printi(n) printf("%d",n); #define inf ((1<<29)-1) #define linf ((1LL<<60)-1) const double eps = 1e-9; set < ll > s ; set < ll > :: iterator it ; vector < ll > v ; int n,m,q ; char a[N] ; int main() { int i , j , t ; sc(n) ; scanf("%s",a) ; string numbers,lower,special, upper ; numbers = "0123456789" ; lower = "abcdefghijklmnopqrstuvwxyz" ; upper = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" ; special = "!@#$%^&*()-+" ; int x,y,z,w; x=0; y=0; z=0; w=0; for(i = 0 ; i < numbers.length(); i++ ) { for(j = 0 ; j < n ; j++ ) { if(numbers[i] == a[j]) x=1; } } for(i = 0 ; i < lower.length(); i++ ) { for(j = 0 ; j < n ; j++ ) { if(lower[i] == a[j]) y=1; } } for(i = 0 ; i < upper.length(); i++ ) { for(j = 0 ; j < n ; j++ ) { if(upper[i] == a[j]) z=1; } } for(i = 0 ; i < special.length(); i++ ) { for(j = 0 ; j < n ; j++ ) { if(special[i] == a[j]) w=1; } } int ans = 0 ; //printf("x = %d\n",x) ; if(x == 0) { ans++ ; n++ ; } if(y == 0) { ans++ ; n++ ; } if(z == 0) { ans++ ; n++ ; } if(w == 0) { ans++ ; n++ ; } printf("%d\n",ans+max(0,6-n)) ; return 0 ; }