year = int(input())
if (year - 8) % 12 == 0:
    print("Dragon")
if (year - 8) % 12 == 1:
    print("Snake")
if (year - 8) % 12 == 2:
    print("Horse")
if (year - 8) % 12 == 3:
    print("Sheep")
if (year - 8) % 12 == 4:
    print("Monkey")
if (year - 8) % 12 == 5:
    print("Rooster")
if (year - 8) % 12 == 6:
    print("Dog")
if (year - 8) % 12 == 7:
    print("Pig")
if (year - 8) % 12 == 8:
    print("Rat") 
if (year - 8) % 12 == 9:
    print("Ox")
if (year - 8) % 12 == 10:
    print("Tiger")
if (year - 8) % 12 == 11:
    print("Hare")
