Skip to content

Commit de7865c

Browse files
committed
docs: fix broken examples on the "Data types" page
1 parent 3b3be52 commit de7865c

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

docs/datatypes/index.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,11 @@ math.add(300000000000000000n, 1n) // 300000000000000001n
3737
// use Fractions
3838
math.add(math.fraction(1), math.fraction(3)) // Fraction, 0.(3)
3939

40-
// use strings
41-
math.add('hello ', 'world') // 'hello world'
42-
math.max('A', 'D', 'C') // 'D'
40+
// use strings containing numbers
41+
math.add('2', '3') // 5
42+
math.concat('2', '3') // '23'
43+
math.max('3', '2', '7') // 7
44+
math.compareNatural('10', '2') // 1
4345

4446
// use complex numbers
4547
const a = math.complex(2, 3) // 2 + 3i

0 commit comments

Comments
 (0)