input: Write a function that validates a decimal up to 2 decimal places.
  assert is_decimal('123.11')==True
  assert is_decimal('e666.86')==False
  assert is_decimal('3.124587')==False
output: def is_decimal(string):
      try:
          parts = string.split('.')
          if len(parts) != 2:
              return False
          integer_part, decimal_part = parts
          if not integer_part.isdigit() or not decimal_part.isdigit():
              return False
          if len(decimal_part) > 2:
              return False
          return True
      except Exception:
          return False