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 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a11a564bb5e4dd56 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-09-28 14:30:23 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!router1.news.adelphia.net!rip!newsfeeds-atl2!news.webusenet.com!pc01.webusenet.com!e3500-atl2.usenetserver.com.POSTED!not-for-mail From: "gilrain" Newsgroups: comp.lang.ada References: Subject: Re: Trouble with s'fraction attribute. X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Message-ID: X-Complaints-To: abuse@usenetserver.com X-Abuse-Info: Please be sure to forward a copy of ALL headers X-Abuse-Info: Otherwise we will be unable to process your complaint properly. NNTP-Posting-Date: Sat, 28 Sep 2002 17:25:45 EDT Organization: WEBUSENET.com Date: Sat, 28 Sep 2002 16:32:20 -0500 Xref: archiver1.google.com comp.lang.ada:29408 Date: 2002-09-28T16:32:20-05:00 List-Id: That's what I wanted. Thanks a lot! John Thile "David C. Hoos, Sr." wrote: > You need to re-read the definition of the 'Fraction attribute. > What you probably want is the 'Remainder attribute, of which > an example is presented here: > > with ada.text_io, ada.float_text_io; > use ada.text_io, ada.float_text_io; > procedure remainder is > number, int, fl : float; > begin > number := 3.141592654; > > int := float'truncation(number); > fl := float'remainder(Number,int); > > put(int); new_line; > put(fl); > end remainder;