FM> notice that I was endeavoring, without success, to "fix" the problem that
t
FM> DIVISION process needs floats rather than ints if THAT answer is to be
FM> accurate. I, apparently, didn't gain anything by separating the Calc
varia
Why not use a quotient/remainder for the division.
void divide(int x, int y, int* quo, int* rem = 0);
you can call it like
int quo; int rem;
divide(5,2,&quo);
divide(5,2,&quo,&rem);
In the procedure just test rem != 0 to see if you need to
calculate a remainder.
--- GEcho 1.00
---------------
* Origin: Digital OnLine Magazine! - (409)838-8237 (1:3811/350)
|