Re: your mail

From: Sean Butler (sbutler@DEVEAST.COM)
Date: 11/08/97


->My question is will this lag the mud having to continually run through a
->for loop of up to say 200 names?

Daniel Wrote:

>Doing anything a lot will take up time.  The worst case scenario is
>that we go through all 200 names.  So, worst case for the 5 humans
>walking into a room with 10 humans is:
>
> 200 * 15 * 14 = 42000 searches

Actually, with a sorted list of idnumbers:

log(200) * 15 * 14 = 1680
   2
is the worst case.  And its not searches, it's comparisons.

1680 integer comparisons would not take much time at all.

--Sean




     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST