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,db88d0444fafe8eb X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!news4.google.com!news.glorb.com!feeder.xsnews.nl!feeder.news-service.com!colt.net!fr.colt.net!teaser.fr!oleane.net!oleane!hunter.axlog.fr!nobody From: Jean-Pierre Rosen Newsgroups: comp.lang.ada Subject: Re: Arrays indexed by fixed point types (Was: Surprise in array concatenation) Date: Mon, 05 Sep 2005 13:07:33 +0200 Organization: Adalog Message-ID: References: <1125544603.561847.32140@g47g2000cwa.googlegroups.com> <1125610942.747981.280770@f14g2000cwb.googlegroups.com> NNTP-Posting-Host: mailhost.axlog.fr Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Trace: s1.news.oleane.net 1125921665 14131 195.25.228.57 (5 Sep 2005 12:01:05 GMT) X-Complaints-To: abuse@oleane.net NNTP-Posting-Date: Mon, 5 Sep 2005 12:01:05 +0000 (UTC) User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716) X-Accept-Language: fr, en In-Reply-To: Xref: g2news1.google.com comp.lang.ada:4438 Date: 2005-09-05T13:07:33+02:00 List-Id: Jacob Sparre Andersen a �crit : > I find that definition of arrays rather limited. > > I have some cases, where my problem is to store data in an array > indexed by an approximation of real numbers. The most obvious (and > recurring) example is a histogram of real valued samples. As it is > now, I have to mess around with mapping my (approximated) real numbers > onto an integer scale and back again. > If you want to associate values to arbitrary elements, use a map. Arrays are for discrete indices. -- --------------------------------------------------------- J-P. Rosen (rosen@adalog.fr) Visit Adalog's web site at http://www.adalog.fr