[Q]uestions regarding collections
Jon Hylands
jon at huv.com
Sun Aug 19 00:11:16 UTC 2001
On Sat, 18 Aug 2001 21:59:35 +0200, "Raymond Tiefenthal"
<r.tiefenthal at gmx.de> wrote:
> 3. I was asking myself, why SortedCollection doesn't overwrite # indexOf:
> for instance, in order to perform a binary search.
In order to do a binary search, you have to know whether the collection is
sorted ascending or descending.
Without knowing what the sort block does, I can't see how the collection
could figure out which way to go after the first comparison...
Later,
Jon
--------------------------------------------------------------
Jon Hylands Jon at huv.com http://www.huv.com/jon
Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
http://www.huv.com
More information about the Squeak-dev
mailing list
|