Is there a function to constrain an int to be with...
# announcements
k
Is there a function to constrain an int to be within a range? Eg
Copy code
(3..8).clamp(5) == 5
(3..8).clamp(1) == 3
(3..8).clamp(9) == 8