piclist 2001\04\08\072613a >
Thread: Rounding to closest 1's multiple, code enclosed :)
face BY : Kübek Tonyemail (remove spam text)


Bob Ammeroman wrote: ( correct this time :) )

>Bravo, bravo!

as an reply to Scott Dattalo's posting:

> I'd like to expand on Bob's idea a little.
> To recap, we have a 24bit number and we'd like to find a smaller number
that is
> congruent to it modulo 5. In other words, if we divide the 24 bit number
by 5
> and the smaller number by 5 we get the same remainder. Perhaps a little
> can illustrate the pattern:

<big snip>

I'm in awe,
I was looking for a 'clever' way to round variables
particulary 24 bit ones and You outshined everything I
could envision.


Tony Kübek, Flintab AB            
E-mail: TakeThisOuTtony.kubekspamspamflintab.com

http://www.piclist.com hint: The list server can filter out subtopics
(like ads or off topics) for you. See http://www.piclist.com/#topics

<200104081117.NAA01957@mn10.swip.net> quoted-printable

See also: www.piclist.com/techref/microchip/devices.htm?key=pic
Reply You must be a member of the piclist mailing list (not only a www.piclist.com member) to post to the piclist. This form requires JavaScript and a browser/email client that can handle form mailto: posts.
Subject (change) Rounding to closest 1's multiple, code enclosed :)

month overview.

new search...