Class: Diakonos::NumberFitter
Class Method Summary collapse
Class Method Details
.fit(number:, min:, max:) ⇒ Object
3 4 5 6 7 8 |
# File 'lib/diakonos/number-fitter.rb', line 3 def self.fit(number:, min:, max:) return number if max < min return min if number < min return max if number > max return number end |