import threading

def con(i):
    try:
        if i==a*a*a+b*b*b+c*c*c:
            print(i)
    except:
        pass

for i in range(100,1000):
    a=int(i/100)
    b=int(i%100/10)
    c=i%10
    t=threading.Thread(target=con,args=(i,))
    t.start()