We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c872535 commit 95df435Copy full SHA for 95df435
test/src/ZZ/minmax.js
@@ -0,0 +1,21 @@
1
+import test from 'ava' ;
2
+
3
+import { ZZ } from '../../../src' ;
4
5
+test( 'minmax' , t => {
6
7
+ const a = ZZ.from('1037193691267387921739639472846392869238466298463928649236') ;
8
+ const b = ZZ.from('102833047307209370991273091273') ;
9
+ const c = ZZ.from('-18039809213809128309123702149836492649632832') ;
10
+ const d = ZZ.from(-3) ;
11
12
+ t.is( a , ZZ.max(a, b) ) ;
13
+ t.is( a , ZZ.max(b, a) ) ;
14
+ t.is( b , ZZ.min(a, b) ) ;
15
+ t.is( b , ZZ.max(b, c) ) ;
16
+ t.is( c , ZZ.min(c, d) ) ;
17
+ t.is( c , ZZ.min(b, c) ) ;
18
+ t.is( d , ZZ.min(b, d) ) ;
19
+ t.is( d , ZZ.max(d, c) ) ;
20
21
+}) ;
0 commit comments