diff options
| author | shigek <shigek@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-08-29 13:37:44 +0000 |
|---|---|---|
| committer | shigek <shigek@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-08-29 13:37:44 +0000 |
| commit | 12574146413addddc350c7aab7a579d89e05f2e4 (patch) | |
| tree | ec80a3e38f19d317134ba58358572371596f6943 /ext/bigdecimal/bigdecimal_en.html | |
| parent | d6382f7da70b88dbaf3c73a660f57ecbc675d277 (diff) | |
| download | ruby-12574146413addddc350c7aab7a579d89e05f2e4.tar.gz ruby-12574146413addddc350c7aab7a579d89e05f2e4.tar.xz ruby-12574146413addddc350c7aab7a579d89e05f2e4.zip | |
The 2nd arg for add,sub,mult, and div is 0, then result will be same as +,-,*,/ respectively.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@4461 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/bigdecimal/bigdecimal_en.html')
| -rw-r--r-- | ext/bigdecimal/bigdecimal_en.html | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/ext/bigdecimal/bigdecimal_en.html b/ext/bigdecimal/bigdecimal_en.html index 1197be15b..7f6faa39b 100644 --- a/ext/bigdecimal/bigdecimal_en.html +++ b/ext/bigdecimal/bigdecimal_en.html @@ -238,30 +238,33 @@ For the resulting number of significant digits of c,see <A HREF="#PREC">Resultin <LI><B>add(b,n)</B></LI><BLOCKQUOTE> c = a.add(b,n)<BR> -c = a.add(b,n) performs c = a + b. +c = a.add(b,n) performs c = a + b.<BR> If n is less than the actual significant digits of a + b, -then c is rounded properly according to the BigDecimal.limit. - +then c is rounded properly according to the BigDecimal.limit.<BR> +If n is zero,then the result is the same as +'s. </BLOCKQUOTE> <LI><B>sub(b,n)</B></LI><BLOCKQUOTE> c = a.sub(b,n)<BR> -c = a.sub(b,n) performs c = a - b. +c = a.sub(b,n) performs c = a - b.<BR> If n is less than the actual significant digits of a - b, -then c is rounded properly according to the BigDecimal.limit. +then c is rounded properly according to the BigDecimal.limit.<BR> +If n is zero,then the result is the same as -'s. </BLOCKQUOTE> <LI><B>mult(b,n)</B></LI><BLOCKQUOTE> c = a.mult(b,n)<BR> -c = a.mult(b,n) performs c = a * b. +c = a.mult(b,n) performs c = a * b.<BR> If n is less than the actual significant digits of a * b, -then c is rounded properly according to the BigDecimal.limit. +then c is rounded properly according to the BigDecimal.limit.<BR> +If n is zero,then the result is the same as *'s. </BLOCKQUOTE> <LI><B>div(b[,n])</B></LI><BLOCKQUOTE> c = a.div(b,n)<BR> -c = a.div(b,n) performs c = a / b. +c = a.div(b,n) performs c = a / b.<BR> If n is less than the actual significant digits of a / b, then c is rounded properly according to the BigDecimal.limit.<BR> +If n is zero,then the result is the same as /'s. If n is not given,then the result will be an integer(BigDecimal) like Float#div. </BLOCKQUOTE> |
