input: Write a Python function that transforms an octal number into a decimal equivalent.
  assert octal_to_decimal(25) == 21
  assert octal_to_decimal(30) == 24
  assert octal_to_decimal(40) == 32
output: def octal_to_decimal(octal):
      decimal = 0
      power = 0
      while octal > 0:
          decimal += (octal % 10) * (8 ** power)
          octal //= 10
          power += 1
      return decimal