uniq
no way to compare when less than two revisions
Differences
This shows you the differences between two versions of the page.
— | uniq [2006/08/29 16:08] (current) – created - external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | # $EPIC: uniq.txt,v 1.2 2006/08/20 17:37:08 sthalik Exp $ | ||
+ | ======Synopsis: | ||
+ | $__uniq__(< | ||
+ | |||
+ | ======Technical: | ||
+ | * If the <word list> argument is omitted the empty string is returned. | ||
+ | * In all circumstances, | ||
+ | * The implementation of this function is equivalent to: | ||
+ | |||
+ | fe ($*) x { | ||
+ | if (findw($x $function_return) == -1) { | ||
+ | push function_return $x | ||
+ | } | ||
+ | } | ||
+ | |||
+ | * This function uses a O(N^2) algorithm and can perform very slowly for large inputs. | ||
+ | |||
+ | ======Practical: | ||
+ | This function returns all of the words in <word list> after all of | ||
+ | the duplicates are removed. | ||
+ | |||
+ | ======Returns: | ||
+ | list of the unique words in <word list> | ||
+ | |||
+ | ======Examples: | ||
+ | < | ||
+ | $uniq(one two three two one) | ||
+ | $uniq(one | ||
+ | $uniq(blah blah blah) returns " | ||
+ | </ | ||
+ | |||
+ | ======History: | ||
+ | This function first appeared in EPIC3.001. | ||
uniq.txt · Last modified: 2006/08/29 16:08 by 127.0.0.1