In C#, one can easily get the quotient and modulus of an integer division:
var quotient = 7 / 3;
var modulus = 7 % 3;
However, as far as I can tell it doesn't have a divmod
function, allowing you to get both at once. Is there a way to do this? Getting them separately would seem to require the divison to be done twice, unnecessarily, as the processor surely provides both values at the same time for one division.