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-Thread: 103376,edafb2ab7e8839bc X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!news4.google.com!news.glorb.com!wns13feed!worldnet.att.net!attbi_s71.POSTED!53ab2750!not-for-mail From: "Jeffrey R. Carter" Organization: jrcarter at acm dot org User-Agent: Thunderbird 1.5.0.8 (Windows/20061025) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Char type verification References: <1163628033.606530.190550@i42g2000cwa.googlegroups.com> <1163627827.1632.10.camel@localhost.localdomain> <1163632532.101867.123200@m73g2000cwd.googlegroups.com> <455cf4f8$0$17901$426a74cc@news.free.fr> In-Reply-To: <455cf4f8$0$17901$426a74cc@news.free.fr> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: NNTP-Posting-Host: 12.201.97.213 X-Complaints-To: abuse@mchsi.com X-Trace: attbi_s71 1163724497 12.201.97.213 (Fri, 17 Nov 2006 00:48:17 GMT) NNTP-Posting-Date: Fri, 17 Nov 2006 00:48:17 GMT Date: Fri, 17 Nov 2006 00:48:17 GMT Xref: g2news2.google.com comp.lang.ada:7516 Date: 2006-11-17T00:48:17+00:00 List-Id: Yves Bailly wrote: > > As I understand it, the real question was : "having a list of contiguous > values of some type, how to know if a given value of that same type is > contained into the list". It's a kind of basic hashing: you can assume > to always be able to map your type's values to integers. So you can > replace "list of contiguous values" by "range of values". The real question was: "how would you convert this to Ada." This was then repeated as: "How do you translate this example to Ada?" Since the code presented determined whether a character was in 'A' .. 'Z', he should not be surprised to receive answers that used "in 'A' .. 'Z'". I'm sorry, but I don't accept that someone who's able to write the example is unable to ask, "How do you convert a character to an integer?" or, "How do you determine if a value is in a range of values?" if that's what he really wanted to ask. -- Jeff Carter "Hello! Smelly English K...niggets." Monty Python & the Holy Grail 08