This shows you the differences between two versions of the page.
— |
notw [2007/03/02 02:32] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | # $EPIC: notw.txt,v 1.4 2007/03/02 02:32:04 jnelson Exp $ | ||
+ | ======Synopsis:====== | ||
+ | $__notw__(<number> <word list>) | ||
+ | |||
+ | ======Technical:====== | ||
+ | * If the <number> argument is omitted the empty string is returned. | ||
+ | * If the <number> argument is negative, <word list> is returned. | ||
+ | * The return value of this function is <word list> with the <number>th word omitted, counting from zero. | ||
+ | * Extra spaces surrounding the <number>th word will be removed. | ||
+ | * Remember that <word list> is a list of [[what is a word|words]]. | ||
+ | |||
+ | ======Practical:====== | ||
+ | Useful when you want to remove a word from a word list. | ||
+ | |||
+ | ======Returns:====== | ||
+ | The <word list> argument without the <number>th word, counting from zero. | ||
+ | |||
+ | ======Examples:====== | ||
+ | <file> | ||
+ | $notw(0 hello there how are you?) returns "there how are you?" | ||
+ | $notw(2 hello there how are you?) returns "hello there are you?" | ||
+ | $notw(-1 hello there how are you?) returns "hello there how are you?" | ||
+ | </file> | ||
+ | |||
+ | ======History:====== | ||
+ | This function first appeared in "plus-2" (post-ircII, pre-EPIC) | ||