-->

AD

 DECLARE SUB CHECK(N)

Cls

Input "ENTER ANY NUMBER"; N

Call CHECK(N)

End


Sub CHECK (N)

    P = N

    While N <> 0

        R = N Mod 10

        A = A + R ^ 3

        N = N / 10

    Wend

    If A = P Then

        Print "IT IS AN ARMSTRONG NUMBER"

    Else

        Print "IT IS NOT AN ARMSTRONG NUMBER"

    End If

End Sub


2 Comments

Post a Comment

Previous Post Next Post
CLOSE ADS
CLOSE ADS