You are viewing a single comment's thread from:

RE: Help me with this JAVA bug!

in #java6 years ago

The logic should be:
while(n!=0)
(
b=n%10;
a=a+Math.pow(b,3);
n=n/10;
)
Sorry I don't have flowerbrackets on my keyboard so used round brackets for encapsulating the block.
This is my 9th grade problem so I still remember. This will work. And good to see a person with so much interest to learn programming. You can ask me questions related to programming whenever you want. All the best buddy. It will work.

Coin Marketplace

STEEM 0.20
TRX 0.25
JST 0.038
BTC 97445.74
ETH 3477.06
USDT 1.00
SBD 3.16