# $EPIC: chngw,v 1.5 2001/07/16 23:14:15 jnelson Exp $
Synopsis::
   $chngw(<index> <word> <word list>)

Technical:
   * If the <index> argument is omitted the empty string is returned.
   * If the <what> argument is omitted the empty string is returned.
   * If the <index> argument is less than 0 then <word list> is returned.
   * The return value if <word list> with the <index>th word, counting from
     zero, changed to <word>.
   * Historically <word list> does not support double-quoted words.
     This may change in the future.  Try using /xdebug extractw.

Practical:
   If you need to change one of the words in a word list, use this function.
   I originally used this function to permit changes to access levels on my
   bot on the fly.

Returns:
   <word list> with the <index>th word changed to <word>, counting from zero.

Examples:
   $chngw(2 blah foo bar booya)          returns "foo bar blah"

History:
   This function first appeared in "plus-2" (post-ircII, pre-EPIC)

See also:
   insertw(6); remw(6); splice(6)
