Hi, This is just for fun, really, but does anyone know how the nub function from the standard List module got its name? (It is the function that removes duplicates from a list, in case you are not familiar with it.) I looked up the word "nub" in the online Merriam-Webster dictionary (www.m-w.com) and it gives: 1 : KNOB, LUMP 2 : NUBBIN 3 : GIST, POINT Then the entry for "nubbin" says: 1 : something (as an ear of Indian corn) that is small for its kind, stunted, undeveloped, or imperfect 2 : a small usually projecting part or bit 3 : NUB 3 So which sense of the word was the function named for? Could a list with stuff removed from it be considered "stunted"? Or maybe the set of unique elements from a list would be like the "main point" or "gist" of the list? If so, maybe "List.nub" could just as well have been named "List.gist" instead. Anyway, I'd be interested to learn anything about the history and naming of "nub", or any other library functions, for that matter. - Brian Huffman
On Fri, May 24, 2002 at 10:00:35AM -0700, Brian Huffman wrote:
Hi,
This is just for fun, really, but does anyone know how the nub function from the standard List module got its name? (It is the function that removes duplicates from a list, in case you are not familiar with it.) I looked up the word "nub" in the online Merriam-Webster dictionary (www.m-w.com) and it gives:
1 : KNOB, LUMP 2 : NUBBIN 3 : GIST, POINT
The first result for nub in dictionary.com gives: nub Pronunciation Key (nb) n. 1. A protuberance or knob. 2. A small lump. 3. The essence; the core: the nub of a story I think essence is the right meaning, removing all duplicates. Cheers, -- Tom
On Fri, 24 May 2002, Tom Schrijvers wrote:
The first result for nub in dictionary.com gives: nub Pronunciation Key (nb) n.
1. A protuberance or knob. 2. A small lump. 3. The essence; the core: the nub of a story
I think essence is the right meaning, removing all duplicates. Cheers, -- Tom
Yes, that was the reason for the name. John
participants (3)
-
Brian Huffman -
John Hughes -
Tom Schrijvers