MCPcopy Create free account
hub / github.com/rsc/tmp / DivMod

Method DivMod

bootstrap/internal/gc/big/int.go:286–302  ·  view source on GitHub ↗

DivMod sets z to the quotient x div y and m to the modulus x mod y and returns the pair (z, m) for y != 0. If y == 0, a division-by-zero run-time panic occurs. DivMod implements Euclidean division and modulus (unlike Go): q = x div y such that m = x - y*q with 0 <= m < |q| (See Raymond T. Bou

(x, y, m *Int)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

TestDivisionSignsFunction · 0.45

Calls 5

QuoRemMethod · 0.95
AddMethod · 0.95
SubMethod · 0.95
aliasFunction · 0.85
SetMethod · 0.65

Tested by 1

TestDivisionSignsFunction · 0.36