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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,c8faa961aaf3fddb X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!postnews.google.com!p10g2000cwp.googlegroups.com!not-for-mail From: "isaac2004" Newsgroups: comp.lang.ada Subject: Re: help with string splitting Date: 8 Mar 2006 21:54:09 -0800 Organization: http://groups.google.com Message-ID: <1141883649.513514.212680@p10g2000cwp.googlegroups.com> References: <1141863131.984654.144550@j52g2000cwj.googlegroups.com> <4jMPf.4128$6I.3573@newsread3.news.pas.earthlink.net> NNTP-Posting-Host: 67.170.5.168 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: posting.google.com 1141883654 15982 127.0.0.1 (9 Mar 2006 05:54:14 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Thu, 9 Mar 2006 05:54:14 +0000 (UTC) In-Reply-To: <4jMPf.4128$6I.3573@newsread3.news.pas.earthlink.net> User-Agent: G2/0.2 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: p10g2000cwp.googlegroups.com; posting-host=67.170.5.168; posting-account=bWy1LAwAAAAtVkasDCH0ykMCBMNd-FcL Xref: g2news1.google.com comp.lang.ada:3300 Date: 2006-03-08T21:54:09-08:00 List-Id: First_Half_Index : Positive := 1; Second_Half_Index : Positive := 2; >for Code_Index in Codetext'Length loop > if Code_Index <= Codetext'Length / 2 then > Plaintext(First_Half_index) := Codetext(Code_Index); > First_Half_Index := First_Half_Index + 2; > else > Plaintext(Second_Half_Index) := Codetext(Code_Index); > Second_Half_Index := Second_Half_Index + 2; > end if; >end loop; this code confuses me what is Code_Index and Codetext'Length >Your two examples above do not agree. >Following the encrypted example, Mother would encrypt to >Mteohr. I suspect that may have been a slip of the fingers during >typing, but it does add confusion to your requirements. that is my mistake it is really Mteohr >Now Length is the # of characters read + 1. the reason for doing that is to loop through the string and reading all char to length. thanks for the help guys