code: def day_fraction(time):
      
      hour = int(time.split(":")[0])
      minute = int(time.split(":")[1])
      return hour/24 + minute/1440
docs: Convert a 24-hour time to a fraction of a day.
  
      For example, midnight corresponds to 0.0, and noon to 0.5.
  
      :param time: Time in the form of 'HH:MM' (24-hour time)
      :type time: string
  
      :return: A day fraction
      :rtype: float
  
      :Examples:
  
      .. code-block:: python
  
          day_fraction("18:30")