comp.lang.ada
 help / color / mirror / Atom feed
From: "DuckE" <nospam_steved94@home.com>
Subject: Re: Natural to String without space? (newbie question)
Date: Wed, 23 May 2001 22:37:02 GMT
Date: 2001-05-23T22:37:02+00:00	[thread overview]
Message-ID: <iYWO6.48839$p33.976198@news1.sttls1.wa.home.com> (raw)
In-Reply-To: 3B0BD493.5ABBA12B@labe.felk.cvut.cz

I don't know if it's the easiest way, but there is a function in
Ada.Strings.Fixed called "Trim" that may be used to eliminate leading and
trailing spaces.

For example:

  Put( Trim( Natural'IMAGE( value ), both )  );

FYI: I recommend browsing through Appendix A of the Ada 95 reference manual.
This appendix has descriptions of the standard library included with Ada 95.

I hope this helps,
SteveD


"Tomas Hlavaty" <hlavaty@labe.felk.cvut.cz> wrote in message
news:3B0BD493.5ABBA12B@labe.felk.cvut.cz...
> Natural'Image returns string with space at the begining. Is there any
> standard way how to get number without this additional character?
>
> Thanks,
>
> Tomas





  reply	other threads:[~2001-05-23 22:37 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-05-23 15:17 Natural to String without space? (newbie question) Tomas Hlavaty
2001-05-23 22:37 ` DuckE [this message]
2001-05-24  6:33 ` Pascal Obry
2001-05-29 21:04   ` Wes Groleau
2001-05-29 23:00     ` Jeffrey Carter
2001-05-30  7:19     ` Pascal Obry
  -- strict thread matches above, loose matches on Subject: below --
2001-05-23 22:45 Beard, Frank
2001-05-24  7:56 ` Martin Dowie
2001-05-24 21:55 Beard, Frank
2001-05-25  7:30 ` Martin Dowie
2001-05-25  8:30   ` Tomas Hlavaty
2001-05-25 15:05   ` Ehud Lamm
2001-05-28  7:31     ` Martin Dowie
2001-05-25 21:23   ` Ole-Hjalmar Kristensen
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox