From: Bardur A. <oca...@sc...> - 2004-09-11 06:18:34
|
On Wed, Sep 08, 2004 at 05:01:15PM -0500, Brian Hurt wrote: > - added splice, return a subset of an indexed tree. This takes either > O(log N) where N is the length of the source tree, or O((log M)^2) where > M is the length of the returned tree. I can't think of a better way of > doing this- suggestions welcomed. No suggestions on better ways to do it, but I don't think the name is quite appropriate. If "splice" is used in verb form it can only (well, according to M-W online) be used in the sense of insertion, not extraction. In the noun form it just refers to a "a joining or joint made by splicing something". I would have suggested "slice" just to be consistent with ExtString.String.slice, but since it uses the (index,len) approach instead of (first,last) and is also much stricter it might be confusing to use the same name. How about "sub"? That's what this operation is called for regular arrays and strings... -- Bardur Arantsson <ba...@im...> <ba...@sc...> - Your Neutralness, it's a beige alert! - If I don't survive, tell my wife "Hello." Neutral Vice President and Neutral President | Futurama |