import math H, W = map(int, input().split()) GCD = math.gcd(H, W) H //= GCD W //= GCD print(['YOKO', 'TATE'][(H, W) == (4, 3)])