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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9b52255462d75ee8 X-Google-Attributes: gid103376,public From: Darel Cullen Subject: Re: formatting numbers on output Date: 1996/08/18 Message-ID: #1/1 X-Deja-AN: 174898220 distribution: world x-nntp-posting-host: djcull.demon.co.uk references: <4v2r77$lal@hermes.acs.unt.edu> organization: my bedroom mime-version: 1.0 newsgroups: comp.lang.ada Date: 1996-08-18T00:00:00+00:00 List-Id: In article <4v2r77$lal@hermes.acs.unt.edu>, "Ramesh S. Mantri" writes >Is formatting numbers on output possible in Ada, the way it is >permitted in other languages such as Fortran, Pascal, C and others? >Because it is displaying even small numbers in a large space. As a >result, the output does not look too good. >Thanks in advance. >--- Ramesh Mantri Sure.. Check out the extra parameters WIDTH, BASE, AFT, EXP, on Text_io for Integer_io and Float_io.. They are pretty self explaining. AFT and EXP relate to floating point numbers and positioning of the point. WIDTH is what you are after , this specifies the size of field to display your small numbers in. more complicated screen formatting becomes a little complex in ada 83 at any rate.. usually you end up having to output vt100 or ansi codes in your Put statement to position the cursor on the screen. -- Darel Cullen