input: Write a function to calculate the sum of the digits in a given number. The function should take an integer as input and return the sum of its digits. If the input number is negative, consider it as positive for the calculation.
  
  def sum_digits(num):
      total = 0
      num = abs(num)
      while num > 0:
          digit = num % 10
          total += digit
          num = num // 10
      return total
  
  assert sum_digits(123) == 6
  assert sum_digits(-123) == 6
  assert sum_digits(0) == 0
  assert sum_digits(987654321) == 45
  assert sum_digits(111111) == 6
output: def sum_digits(num):
      total = 0
      num = abs(num)
      while num > 0:
          digit = num % 10
          total += digit
          num = num // 10
      return total