mpetrovich/dash

Add clamp()

Closed this issue · 0 comments

clamp($v, $min, $max) returns $min if $v < $min
                              $max if $v > $max
                              $v if $min <= $v <= $max