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=0.1 required=5.0 tests=BAYES_05,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII X-Google-Thread: 103376,99bed60f2de3a39c X-Google-Attributes: gid103376,public From: John McCabe Subject: Re: coercing an integer to a string Date: 1998/11/16 Message-ID: <72ovh9$6m2@gcsin3.geccs.gecm.com>#1/1 X-Deja-AN: 412706133 Content-Transfer-Encoding: 8bit References: <87af1s3zvw.fsf@mihalis.ix.netcom.com> Content-Type: text/plain; charset=iso-8859-1 Organization: Avatar Computer Consultants Limited Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 1998-11-16T00:00:00+00:00 List-Id: Chris Morgan wrote: >dummy@e.mail (Emmanuel M. D�carie) writes: >Think about it a bit. Function 1 requires you to build up a string >piece by piece. Can you work out how to decide how many 1000s, 100s, >10s, units and so on the number contains? Then you would just need to >work out how to join the characters together. > >Similarly the 2nd function - work out what each character means in >terms of numerical value and then add them together. It's not as hard >as it seems. It's even easier than it seems if you use the facilities of the language that Tom Moran has mentioned. -- Best Regards John McCabe --------------------------------------------------------------------- Marconi Electronic Systems Simulation & Training Division ===================================================================== Not necessarily my company or service providers opinions. =====================================================================