object ArmstrongNumber {
def main(args: Array[String]) = {
val input = 153;
var sum = 0;
var armstrongNumber = input;
while (armstrongNumber > 0) {
var i = armstrongNumber % 10;
armstrongNumber = armstrongNumber / 10;
sum += (i * i * i);
}
if (sum == input) {
println("The given number is Armstrong Number");
} else {
println("The given number is NOT a Armstrong Number");
}
}
}