num=n
while(n!=0):
    r=n%10
    s=s+(r*r*r)
    n=int(n/10)
    if(s==num):
        print("the number is Armstrong")
        else:
            print("the number is not Armstrong")
            

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: