code: def duration(message, wpm, output='timedelta', word_ref=WORD, word_spaced=False):
      
      elt_duration = wpm_to_duration(wpm, output=output, word_ref=word_ref)
      word_length = mlength(message, word_spaced=word_spaced)
      return word_length * elt_duration
docs: Calculate duration to send a message at a given code speed
      (calculated using reference word PARIS)
  
      Parameters
      ----------
      word : string
      wpm : int or float - word per minute
      output : String - type of output
          'timedelta'
          'float'
          'decimal'
      word : string - reference word (PARIS by default)
      word_spaced : bool - calculate with spaces between 2 words (default is False)
  
      Returns
      -------
      duration : timedelta or float or decimal.Decimal - duration of the word `word`
  
      >>> duration(_repeat_word('PARIS', 5), 5, word_spaced=True)
      datetime.timedelta(0, 60)
  
      >>> duration('PARIS', 15)
      datetime.timedelta(0, 3, 440000)
  
      >>> duration('SOS', 15)
      datetime.timedelta(0, 2, 160000)