m,n=map(int,input().split()) s=0 for x in range(m,n+1): a=x//100 b=x//10%10 c=x%10 if a**3+b**3+c**3==x: print(x,end=" ") s+=1 if s==0: print("no")