updated bignumbers library

snap7
jmoenig 2021-06-24 18:46:46 +02:00
rodzic d38f9d7134
commit 6c769c2017
2 zmienionych plików z 2 dodań i 1 usunięć

Wyświetl plik

@ -14,6 +14,7 @@
* extensions: tweaked loading unlisted script-extensions
* byob, threads, store: removed unused code
* extensions: added documentation for adding external JS modules
* updated bignumbers library
### 2021-06-23
* updated bignums library

Wyświetl plik

@ -1 +1 @@
<blocks app="Snap! 6, https://snap.berkeley.edu" version="1"><block-definition s="USE BIGNUMS %&apos;bool&apos;" type="command" category="operators"><comment x="0" y="0" w="303.3333333333333" collapsed="false">call with True to turn on the entire Scheme numeric tower, including infinite-precision integers, exact rationals, and complex numbers; call with False to restore native JavaScript arithmetic.</comment><header></header><code></code><translations>pt:altera utilização de aritmética do Scheme para _&#xD;</translations><inputs><input type="%b"></input></inputs><script><block s="doApplyExtension"><l>scr_load(url)</l><list><l>libraries/biginteger.js</l></list></block><block s="doApplyExtension"><l>scr_load(url)</l><list><l>libraries/schemeNumber.js</l></list></block><block s="doApplyExtension"><l>scr_load(url)</l><list><l>libraries/bignums.js</l></list></block><block s="doApplyExtension"><l>big_switch(bool)</l><list><block var="bool"/></list></block></script></block-definition><block-definition s="%&apos;n&apos; !" type="reporter" category="operators"><comment x="0" y="0" w="190.66666666666666" collapsed="false">The factorial function, to make very large numbers, to demo bignums.</comment><header></header><code></code><translations></translations><inputs><input type="%n"></input></inputs><script><block s="doReport"><block s="reportIfElse"><block s="reportEquals"><block var="n"/><l>0</l></block><l>1</l><block s="reportProduct"><block var="n"/><custom-block s="%n !"><block s="reportDifference"><block var="n"/><l>1</l></block></custom-block></block></block></block></script></block-definition><block-definition s="%&apos;x&apos;" type="reporter" category="operators"><comment x="0" y="0" w="234.66666666666666" collapsed="false">The identity function: reports its input.&#xD;It&apos;s useful to get things like 3/4 or 5-2i into&#xD;numeric input slots.</comment><header></header><code></code><translations></translations><inputs><input type="%s"></input></inputs><script><block s="doReport"><block var="x"/></block></script></block-definition><block-definition s="Scheme number %&apos;function&apos; of %&apos;number&apos;" type="reporter" category="operators"><comment x="0" y="0" w="300" collapsed="true">Provides Scheme arithmetic functions not in JavaScript</comment><header></header><code></code><translations>pt:_ de _&#xD;</translations><inputs><input type="%s" readonly="true"><options>number?&#xD;complex?&#xD;real?&#xD;rational?&#xD;integer?&#xD;exact?&#xD;inexact?&#xD;exact&#xD;inexact&#xD;finite?&#xD;infinite?&#xD;nan?&#xD;numerator&#xD;denominator&#xD;real-part&#xD;imag-part&#xD;magnitude&#xD;angle</options></input><input type="%s"></input></inputs><script><block s="doReport"><block s="reportApplyExtension"><l>big_scheme(fn, num)</l><list><block var="function"/><block var="number"/></list></block></block></script></block-definition></blocks>
<blocks app="Snap! 6, https://snap.berkeley.edu" version="1"><block-definition s="USE BIGNUMS %&apos;bool&apos;" type="command" category="operators"><comment w="303.3333333333333" collapsed="false">call with True to turn on the entire Scheme numeric tower, including infinite-precision integers, exact rationals, and complex numbers; call with False to restore native JavaScript arithmetic.</comment><header></header><code></code><translations>pt:altera utilização de aritmética do Scheme para _&#xD;</translations><inputs><input type="%b"></input></inputs><script><block s="doApplyExtension"><l>src_load(url)</l><list><l>libraries/biginteger.js</l></list></block><block s="doApplyExtension"><l>src_load(url)</l><list><l>libraries/schemeNumber.js</l></list></block><block s="doApplyExtension"><l>src_load(url)</l><list><l>libraries/bignums.js</l></list></block><block s="doApplyExtension"><l>big_switch(bool)</l><list><block var="bool"/></list></block></script></block-definition><block-definition s="%&apos;n&apos; !" type="reporter" category="operators"><comment x="0" y="0" w="190.66666666666666" collapsed="false">The factorial function, to make very large numbers, to demo bignums.</comment><header></header><code></code><translations></translations><inputs><input type="%n"></input></inputs><script><block s="doReport"><block s="reportIfElse"><block s="reportEquals"><block var="n"/><l>0</l></block><l>1</l><block s="reportProduct"><block var="n"/><custom-block s="%n !"><block s="reportDifference"><block var="n"/><l>1</l></block></custom-block></block></block></block></script></block-definition><block-definition s="%&apos;x&apos;" type="reporter" category="operators"><comment x="0" y="0" w="234.66666666666666" collapsed="false">The identity function: reports its input.&#xD;It&apos;s useful to get things like 3/4 or 5-2i into&#xD;numeric input slots.</comment><header></header><code></code><translations></translations><inputs><input type="%s"></input></inputs><script><block s="doReport"><block var="x"/></block></script></block-definition><block-definition s="Scheme number %&apos;function&apos; of %&apos;number&apos;" type="reporter" category="operators"><comment x="0" y="0" w="300" collapsed="true">Provides Scheme arithmetic functions not in JavaScript</comment><header></header><code></code><translations>pt:_ de _&#xD;</translations><inputs><input type="%s" readonly="true"><options>number?&#xD;complex?&#xD;real?&#xD;rational?&#xD;integer?&#xD;exact?&#xD;inexact?&#xD;exact&#xD;inexact&#xD;finite?&#xD;infinite?&#xD;nan?&#xD;numerator&#xD;denominator&#xD;real-part&#xD;imag-part&#xD;magnitude&#xD;angle</options></input><input type="%s"></input></inputs><script><block s="doReport"><block s="reportApplyExtension"><l>big_scheme(fn, num)</l><list><block var="function"/><block var="number"/></list></block></block></script></block-definition></blocks>