Issue with documentation

marco.bodrato at tutanota.com marco.bodrato at tutanota.com
Sun Sep 29 12:36:00 CEST 2024


Ciao,

29 set 2024, 09:27 da idcohen2000 at gmail.com:

> "For the ui variants the return value is the remainder, and in fact
> returning the remainder is all the div_ui functions do."
>
> This was confusing to me, so I decided to try it. Indeed the `mpz_tdiv_q_ui`
>  function does actually compute the quotient, as its signature implies.
>

Indeed,
div_q_ui functions compute and store the quotient (and return the remainder);
div_r_ui functions compute and store the remainder (and return the remainder);
div_qr_ui functions compute and store both (and return the remainder);
div_ui functions do "nothing", but (... return the remainder);


> Would it be possible to remove the words "and in fact returning the
> remainder is all the div_ui functions do."?
>
Can you suggest a better way to say that?

Ĝis,
mb


More information about the gmp-bugs mailing list