User Tools

Site Tools


midw

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

midw [2007/03/02 02:32] (current)
Line 1: Line 1:
 +# $EPIC: midw.txt,v 1.4 2007/03/02 02:32:04 jnelson Exp $
 +======Synopsis:​======
 +$__midw__(<​start>​ <​length>​ <word list>)
 +
 +======Technical:​======
 +   * If the <​start>​ argument is omitted the empty string is returned.
 +   * If the <​length>​ argument is omitted the empty string is returned.
 +   * If the <​start>​ argument is less than 0, the empty string is returned.
 +   * If the <​length>​ argument is less than 1, the empty string is returned.
 +   * The return value is the first <​length>​ words of the result of removing the first <​start>​ words from <word list>.
 +   * Remember that <word list> is a list of [[what is a word|words]].
 +
 +======Practical:​======
 +Useful when you want to get some words on the inside of a word list.
 +
 +======Returns:​======
 +Words <​start>​ through <​start>​+<​length>​ in <word list>, counting from zero.
 +
 +======Examples:​======
 +<​file>​
 +$midw(2 2 hello there how are you?)         ​returns "how are"
 +$midw(-1 3 hello there bob)                 ​returns nothing
 +$midw(0 7 hello there bob)                  returns "hello there bob"
 +</​file>​
 +
 +======History:​======
 +This function first appeared in "​plus-2"​ (post-ircII,​ pre-EPIC)
  
midw.txt ยท Last modified: 2007/03/02 02:32 (external edit)