You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
447 B

4 years ago
  1. import _curry2 from "./internal/_curry2.js";
  2. /**
  3. * Returns the larger of its two arguments.
  4. *
  5. * @func
  6. * @memberOf R
  7. * @since v0.1.0
  8. * @category Relation
  9. * @sig Ord a => a -> a -> a
  10. * @param {*} a
  11. * @param {*} b
  12. * @return {*}
  13. * @see R.maxBy, R.min
  14. * @example
  15. *
  16. * R.max(789, 123); //=> 789
  17. * R.max('a', 'b'); //=> 'b'
  18. */
  19. var max =
  20. /*#__PURE__*/
  21. _curry2(function max(a, b) {
  22. return b > a ? b : a;
  23. });
  24. export default max;