From: Paul Shirley Newsgroups: comp.os.msdos.djgpp Subject: Re: fixed point math: NEED HELP QUICK! Date: Thu, 30 Jan 1997 02:15:42 +0000 Organization: wot? me? Lines: 16 Distribution: world Message-ID: References: <5clmjm$ee3 AT nr1 DOT toronto DOT istar DOT net> <199701290130 DOT UAA02417 AT delorie DOT com> Reply-To: Paul Shirley NNTP-Posting-Host: chocolat.foobar.co.uk Mime-Version: 1.0 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp In article <199701290130 DOT UAA02417 AT delorie DOT com>, DJ Delorie writes > >> function. Anyway, here's my problem; To my understanding the following >> are 100% equal: >> >> other_stuff = stuff / 256; >> other_stuff = stuff << 8; > >The second multiplies. Try ">> 8" instead. > And if other_stuff is signed, >>8 and /256 aren't identical either. (which might save you some debugging later ;) --- Paul Shirley: shuffle chocolat before foobar for my real email address