To find the cube of all the digits of the given number. (Qbasic Code)

To find the cube of all the digits of the given number. (Qbasic Code)
  • CLS
    INPUT "Enter a number"; n
    WHILE n <> 0
        r = n MOD 10
        p = r ^ 3
        n = n \ 10
        PRINT "The cube of the digit"; p
    WEND
    END

Share :

Facebook Twitter Google+
Back To Top

facebook main

counter

Powered by Blogger.