comp.lang.ada
 help / color / mirror / Atom feed
From: William Dale <william.dale.jr@lmco.com>
Subject: Re: Rounded off
Date: 1999/06/14
Date: 1999-06-14T00:00:00+00:00	[thread overview]
Message-ID: <37658622.4ECA@lmco.com> (raw)
In-Reply-To: 7jn9af$63i$1@nnrp1.deja.com

Robert Dewar wrote:
> 
> In article <7jmq0c$uq$1@nnrp1.deja.com>,
>   dennison@telepath.com wrote:
> > How about:
> >  Integer(X + 0.5)
> >
> > --
> > T.E.D.
> 
> Ouch! That's a mistake! The proper answer for rounding float
> to integer is of course
> 
>   Integer (X)
> 
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.


You might also look up 

	T'Truncate (X) 
	T'Ceiling (X)
	T'Floor (X) 

All take a float and return the same float type.


-- 

"The difference between hardware and software is that the more you play
with hardware, the more likely you are to break it, but the more you
play with software the more likely you are to FIX it."

Bill Dale 
LMMS
mailto:william.dale.jr@lmco.com
mailto:N2RHV@amsat.org




  reply	other threads:[~1999-06-14  0:00 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-06-09  0:00 Rounded off dginc
1999-06-09  0:00 ` dennison
1999-06-09  0:00   ` David C. Hoos, Sr.
1999-06-10  0:00     ` Robert Dewar
1999-06-10  0:00   ` Robert Dewar
1999-06-14  0:00     ` William Dale [this message]
1999-06-15  0:00     ` czgrr
replies disabled

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