import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static int minimumNumber(int n, String password) { String numbers = "0123456789"; String lower_case = "abcdefghijklmnopqrstuvwxyz"; String upper_case = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; String special_characters = "!@#$%^&*()-+"; int i,x=0,h=0,c=0,l=0,y=0,s=0; for(i=0;i=0) { x=1; } if(lower_case.indexOf(password.charAt(i))>=0) { l=1; } if(upper_case.indexOf(password.charAt(i))>=0) { h=1; } if(special_characters.indexOf(password.charAt(i))>=0) { s=1; } } if(x==0) { c++; } if(l==0) { c++; } if(h==0) { c++; } if(s==0) { c++; } if(c+password.length()<6) { return 6-password.length(); } else { return c; } // Return the minimum number of characters to make the password strong } public static void main(String[] args) { Scanner in = new Scanner(System.in); int n = in.nextInt(); String password = in.next(); int answer = minimumNumber(n, password); System.out.println(answer); in.close(); } }