aboutsummaryrefslogtreecommitdiff
path: root/man/man3/tomo-Num.is_between.3
diff options
context:
space:
mode:
authorBruce Hill <bruce@bruce-hill.com>2025-12-31 15:14:07 -0500
committerBruce Hill <bruce@bruce-hill.com>2025-12-31 15:14:07 -0500
commit41f92837bebae1de783dc7f4a8f880011c72757c (patch)
tree4730711a7c13c19c135d0432be4d1fe9b34c1f77 /man/man3/tomo-Num.is_between.3
parent1f13fa92a87bec65d1760266b108a5485bc14c7a (diff)
parentdbae987f1fb54da795185a03f4c00d56a639f8cd (diff)
Merge branch 'dev' into static-dependencies
Diffstat (limited to 'man/man3/tomo-Num.is_between.3')
-rw-r--r--man/man3/tomo-Num.is_between.39
1 files changed, 5 insertions, 4 deletions
diff --git a/man/man3/tomo-Num.is_between.3 b/man/man3/tomo-Num.is_between.3
index 4276c8e3..ea78d895 100644
--- a/man/man3/tomo-Num.is_between.3
+++ b/man/man3/tomo-Num.is_between.3
@@ -2,7 +2,7 @@
.\" Copyright (c) 2025 Bruce Hill
.\" All rights reserved.
.\"
-.TH Num.is_between 3 2025-11-29 "Tomo man-pages"
+.TH Num.is_between 3 2025-12-31 "Tomo man-pages"
.SH NAME
Num.is_between \- check if a number is in a range
.SH LIBRARY
@@ -23,15 +23,16 @@ lb lb lbx
l l l.
Name Type Description
x Num The integer to be checked.
-low Num The lower bound to check (inclusive).
-high Num The upper bound to check (inclusive).
+low Num One end of the range to check (inclusive).
+high Num The other end of the range to check (inclusive).
.TE
.SH RETURN
-`yes` if `low <= x and x <= high`, otherwise `no`
+`yes` if `a <= x and x <= b` or `b <= x and x <= a`, otherwise `no`
.SH EXAMPLES
.EX
assert (7.5).is_between(1, 10) == yes
+assert (7.5).is_between(10, 1) == yes
assert (7.5).is_between(100, 200) == no
assert (7.5).is_between(1, 7.5) == yes
.EE