From: Austin Obyrne <austin.obyrne@hotmail.com>
Subject: Re: Question: Ordered Loading of an Array.
Date: Sat, 4 Feb 2017 07:34:13 -0800 (PST)
Date: 2017-02-04T07:34:13-08:00 [thread overview]
Message-ID: <afd075a1-98ce-4af0-b1cc-671bdbe88c00@googlegroups.com> (raw)
In-Reply-To: <af359865-6ff7-4995-9739-13d5e50a7a0b@googlegroups.com>
On Saturday, February 4, 2017 at 12:41:05 PM UTC, AdaMagica wrote:
> Am Samstag, 4. Februar 2017 10:55:29 UTC+1 schrieb Austin Obyrne:
>
> Not mentioning typos.
>
> > This_Num : Integer; -- Why isn't this of subtype Index_1?
>
> >
> > SUBTYPE Index_1 IS Integer RANGE 32 .. 126;
> > TYPE This_NumArray IS ARRAY(Index)_1 OF Integer;
> > Cell_Num : This_NumArray:= (others =>0);
> >
> > Input Program:
> >
> > For I in 1 .. 95 Loop ;
> > Ada.Text_IO. Put(Item => "Please enter any integer in the range 32 to 126");
> No range check here! Why?
>
> > Ada.Integer_Text_IO.Get (Item => This_Num);
> > Cell_Num := This_Num; -- What's this line?
>
> > Cell_Num(This_Num) := Cell_Num(This_Num) +1;
Hi,
<This_Num : Integer; -- Why isn't this of subtype Index_1?
This is extraneous - careless of me
As It happens I think I have resolved my problem at home - many thanks - Austin.
next prev parent reply other threads:[~2017-02-04 15:34 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-04 9:55 Question: Ordered Loading of an Array Austin Obyrne
2017-02-04 12:41 ` AdaMagica
2017-02-04 15:34 ` Austin Obyrne [this message]
2017-02-04 16:22 ` Rich
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox