input: Write a function to calculate the sum of the digits of a given number. If the input number is negative, ignore the negative sign and calculate the sum of the digits of the absolute value of the number.
  
  def sum_of_digits(num):
      total = 0
      for ch in str(abs(num)):
          total += int(ch)
      return total
  
  assert sum_of_digits(6342) == 15
  assert sum_of_digits(-6342) == 15
  assert sum_of_digits(0) == 0
  assert sum_of_digits(12345) == 15
  assert sum_of_digits(-12345) == 15
output: def sum_of_digits(num):
      total = 0
      for ch in str(abs(num)):
          total += int(ch)
      return total