/****** BISMILLAH HIR RAHMANIR RAHIM ******/ #include // #include // #include // #include using namespace std; // using namespace __gnu_pbds; // using namespace __gnu_cxx; typedef long long ll; typedef unsigned int ul; typedef unsigned long long ull; typedef vector vi; typedef map mss; typedef map > mvii; typedef map mii; typedef queue qi; typedef map > mvis; typedef map > mvsi; typedef vector vs; typedef pair pii; typedef vector > vpii; // Order Statistic Tree /* Special functions: find_by_order(k) --> returns iterator to the kth largest element counting from 0 order_of_key(val) --> returns the number of items in a set that are strictly smaller than our item */ // typedef tree< // int, // null_type, // less, // rb_tree_tag, // tree_order_statistics_node_update> // ordered_set; #define MP make_pair #define SORT(a) sort (a.begin(), a.end()) #define REVERSE(a) reverse (a.begin(), a.end()) #define ALL(a) a.begin(), a.end() #define PI acos(-1) #define ms(x,y) memset (x, y, sizeof (x)) #define INF 2000000000 #define pb push_back #define MAX 100002 #define debug cout<<"A"<<"\n" #define prnt(a) cout<=b; i--) #define itrALL(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++) #define lc ((node)<<1) #define rc ((node)<<1|1) #define VecPrnt(v) FOR(J,0,v.size()) cout< inline T bigmod(T p,T e,T M) { ll ret = 1; for(; e > 0; e >>= 1) { if(e & 1) ret = (ret * p) % M; p = (p * p) % M; } return (T)ret; } template inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);} template inline T modinverse(T a,T M){return bigmod(a,M-2,M);} template inline T lcm(T a,T b) {a=abs(a);b=abs(b); return (a/gcd(a,b))*b;} template inline bool getbit(T a, X i) { T t=1; return ((a&(t<0);} template inline T setbit(T a, X i) { T t=1;return (a|(t< inline T resetbit(T a, X i) { T t=1;return (a&(~(t<'9';c=getchar())if(c=='-')sign=-1; for(num=0;c>='0'&&c<='9';) { c-='0'; num = num*10+c; c=getchar(); } return num*sign; } inline ll power(ll a, ll b) { ll multiply=1; FOR(i,0,b) { multiply*=a; } return multiply; } /****** END OF HEADER ******/ string numbers = "0123456789"; string lower_case = "abcdefghijklmnopqrstuvwxyz"; string upper_case = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; string special_characters = "!@#$%^&*()-+"; string s; int n; bool oka(string x) { FOR(j,0,x.size()) { FOR(k,0,s.size()) { if(x[j]==s[k]) return true; } } return false; } int main() { // ios_base::sync_with_stdio(0); // cin.tie(NULL); cout.tie(NULL); // freopen("in.txt","r",stdin); int test, cases=1; cin>>n>>s; int cnt=0; if(!oka(numbers)) cnt++; if(!oka(lower_case)) cnt++; if(!oka(upper_case)) cnt++; if(!oka(special_characters)) cnt++; n+=cnt; if(n<6) cnt+=(6-n); prnt(cnt); return 0; }