IN JAVA (using math [modulus...] not a string)
Question 4: Armstrong Number
Write a Java program that prompts a user for an integer. It must then check if the number is an Armstrong number (also known as a narcissistic number or pluperfect digital invariant). An Armstrong number is a number that is equal to the sum of its own digits, each raised to the power of the number of digits in the number.
For example, 153 is an Armstrong number because 1^3 + 5^3 + 3^3 = 153.
Output 1:
Enter a three-digit integer: 153
153 is an Armstrong number.
Output 2:
Enter a three-digit integer: 2ll
2ll is not an Armstrong number.