def judge_pass(password: str): i = 0 j = 0 k = 0 for l in range(len(password)): if password[l].isdecimal(): i = i + 1 elif password[l].isalpha(): j = j + 1 else: k = k + 1 if i > 0 and j > 0 and k > 0: return 1 else: return -1 def replace(chara: str): if chara == "l": return "1" elif chara == "o": return "0" elif chara == "a": return "@" elif chara == "s": return "$" else: return chara chara_l = ["l", "o", "a", "s"] password = input() pass_num = 0 pass_l = [password] counter = 0 for i in range(len(password)): if password[i] in chara_l: for j in range(len(pass_l)): temp_password = pass_l[j] temp_password = temp_password[0:i] + replace(temp_password[i]) + temp_password[i+1:len(password)] pass_l.append(temp_password) for i in range(len(pass_l)): if judge_pass(pass_l[i]) == 1: counter = counter + 1 print(counter)