How to calcutate armstrong number in JAVA