input: Write a function to check if a given number is an Armstrong number by implementing the following steps: Convert the number to its string form to determine the order (number of digits). Initialize a sum to 0 and use a while loop to iterate through each digit of the number. For each digit, raise it to the power of the order and add it to the sum. After the loop, compare the original number with the sum. If they are equal, return True; otherwise, return False. If the given number is 0, return True.
  assert is_armstrong_number(153)==True
  assert is_armstrong_number(9474)==True
  assert is_armstrong_number(123)==False
  assert is_armstrong_number(0)==True
  assert is_armstrong_number(1)==True
output: def is_armstrong_number(num):
      if num == 0:
          return True
      order = len(str(num))
      sum = 0
      temp = num
      while temp > 0:
          digit = temp % 10
          sum += digit ** order
          temp //= 10
      return num == sum