FLINT3.7.0-dev

sdiv_qrnnd

Synopsis#include <flint/longlong.h>
sdiv_qrnnd(q, r, n1, n0, d)source

The signed version of udiv_qrnnd: n_1 B + n_0 and d are signed two's complement integers, the quotient is rounded towards zero and the remainder has the sign of the dividend (as with the C operators / and %). Requires that the quotient fits in an slong.

Guides#

Cite this page

The FLINT team, “sdiv_qrnnd (longlong.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/longlong/sdiv_qrnnd.html (generated 2026-10-20).