n = int(input()) for i in range(n) : tmp = int(input()) if tmp % 40 == 0: print("ikisugi") elif tmp % 10 == 0 : print("sugi") elif tmp % 8 == 0 : print("iki") else : print(tmp / 3)