The prompt seems to have a misunderstanding regarding the range of years. The list of animals corresponds to the Chinese zodiac, which cycles every 12 years. Here's the corrected code:
year = int(input("Введите номер года: ")) animals = ["мышь", "бык", "барс", "заяц", "улитка", "змея", "лошадь", "овца", "обезьяна", "петух", "собака", "кабан"] # Calculate the zodiac animal based on the year zodiac_index = (year - 1) % 12 print(animals[zodiac_index])
кабан
This code will correctly output the corresponding animal for any given year.