#include #include #include #include #include using namespace std; int main() { bool digit = false, upper = false, lower = false, special = false; string numbers = "0123456789"; string lower_case = "abcdefghijklmnopqrstuvwxyz"; string upper_case = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; string special_characters = "!@#$%^&*()-+"; int size, cnt = 0; string str; cin >> size >> str; for (const auto& c : str) { if (numbers.find(c) != str.npos) { digit = true; } else if (lower_case.find(c) != str.npos) { lower = true; } else if (upper_case.find(c) != str.npos) { upper = true; } else if (special_characters.find(c) != str.npos) { special = true; } } cnt = 4 - (digit + upper + lower + special); cnt = max(6 - size, cnt); cout << cnt; /* Enter your code here. Read input from STDIN. Print output to STDOUT */ return 0; }