From df2eaea6a92c7d89d604d0a4e885d064678ce3ed Mon Sep 17 00:00:00 2001 From: "Arnold D. Robbins" Date: Thu, 10 Jul 2014 16:32:44 -0700 Subject: Add div() function for integer division & remainder. --- doc/gawk.1 | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'doc/gawk.1') diff --git a/doc/gawk.1 b/doc/gawk.1 index e3275e87..d5756f08 100644 --- a/doc/gawk.1 +++ b/doc/gawk.1 @@ -13,7 +13,7 @@ . if \w'\(rq' .ds rq "\(rq . \} .\} -.TH GAWK 1 "Apr 17 2014" "Free Software Foundation" "Utility Commands" +.TH GAWK 1 "Jul 10 2014" "Free Software Foundation" "Utility Commands" .SH NAME gawk \- pattern scanning and processing language .SH SYNOPSIS @@ -2629,6 +2629,23 @@ Return the cosine of .IR expr , which is in radians. .TP +.BI div( num ", " denom ", " result ) +Truncate +.I num +and +.I denom +to integers. Return the quotient of +.I num +divided by +.I denom +in \fIresult\fB["quotient"]\fR +and the remainder in +in \fIresult\fB["remainder"]\fR. +This is a +.I gawk +extension, primarily of value when working with +arbitrarily large integers. +.TP .BI exp( expr ) The exponential function. .TP -- cgit v1.2.3