From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,e8550e5b10c2c0 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-02-27 10:09:35 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!wn14feed!worldnet.att.net!204.127.198.203!attbi_feed3!attbi.com!sccrnsc03.POSTED!not-for-mail From: tmoran@acm.org Newsgroups: comp.lang.ada Subject: Re: phone number database References: X-Newsreader: Tom's custom newsreader Message-ID: NNTP-Posting-Host: 12.234.13.56 X-Complaints-To: abuse@attbi.com X-Trace: sccrnsc03 1046369373 12.234.13.56 (Thu, 27 Feb 2003 18:09:33 GMT) NNTP-Posting-Date: Thu, 27 Feb 2003 18:09:33 GMT Organization: AT&T Broadband Date: Thu, 27 Feb 2003 18:09:33 GMT Xref: archiver1.google.com comp.lang.ada:34683 Date: 2003-02-27T18:09:33+00:00 List-Id: >> Six phone numbers: 1795, 2006, 2007, 2012, 2013, 2014. > Use a SAL binary tree If all the OP wants is a Presence test on a small number of possibilities, a simple loop seems appropriate. If high speed is required (seems unlikely for this application...), a Boolean lookup array type Phone_Numbers is range 1000 .. 9999; Is_Present : constant array(Phone_Numbers) of Boolean := (1795 | 2006 | 2007 | 2012 | 2013 | 2014 => True, others=>False); would do the job.