@@ -509,9 +509,9 @@ The return type is `Int` for signed integers of less than system word size, and
509
509
`UInt` for unsigned integers of less than system word size. For all other
510
510
arguments, a common return type is found to which all arguments are promoted.
511
511
512
- The value returned for empty `itr` can be specified by `init` which must be the
513
- additive identity. It is unspecified whether `init` is used for non-empty
514
- collections.
512
+ The value returned for empty `itr` can be specified by `init`. It must be
513
+ the additive identity (i.e. zero) as it is unspecified whether `init` is used
514
+ for non-empty collections.
515
515
516
516
!!! compat "Julia 1.6"
517
517
Keyword argument `init` requires Julia 1.6 or later.
@@ -536,9 +536,9 @@ The return type is `Int` for signed integers of less than system word size, and
536
536
`UInt` for unsigned integers of less than system word size. For all other
537
537
arguments, a common return type is found to which all arguments are promoted.
538
538
539
- The value returned for empty `itr` can be specified by `init` which must be the
540
- multiplicative identity. It is unspecified whether `init` is used for non-empty
541
- collections.
539
+ The value returned for empty `itr` can be specified by `init`. It must be the
540
+ multiplicative identity (i.e. one) as it is unspecified whether `init` is used
541
+ for non-empty collections.
542
542
543
543
!!! compat "Julia 1.6"
544
544
Keyword argument `init` requires Julia 1.6 or later.
@@ -560,9 +560,9 @@ The return type is `Int` for signed integers of less than system word size, and
560
560
`UInt` for unsigned integers of less than system word size. For all other
561
561
arguments, a common return type is found to which all arguments are promoted.
562
562
563
- The value returned for empty `itr` can be specified by `init` which must be the
564
- multiplicative identity. It is unspecified whether `init` is used for non-empty
565
- collections.
563
+ The value returned for empty `itr` can be specified by `init`. It must be the
564
+ multiplicative identity (i.e. one) as it is unspecified whether `init` is used
565
+ for non-empty collections.
566
566
567
567
!!! compat "Julia 1.6"
568
568
Keyword argument `init` requires Julia 1.6 or later.
644
644
Returns the largest result of calling function `f` on each element of `itr`.
645
645
646
646
If provided, `init` must be a neutral element for `max` (i.e. which is less
647
- than any other element) that will be returned for empty collections.
647
+ than or equal to any other element) that will be returned for empty collections.
648
648
649
649
!!! compat "Julia 1.6"
650
650
Keyword argument `init` requires Julia 1.6 or later.
@@ -664,8 +664,9 @@ maximum(f, a; kw...) = mapreduce(f, max, a; kw...)
664
664
minimum(f, itr; [init])
665
665
666
666
Returns the smallest result of calling function `f` on each element of `itr`.
667
- If provided, `init` must be a neutral element for `min` that will be returned
668
- for empty collections.
667
+
668
+ If provided, `init` must be a neutral element for `min` (i.e. which is greater
669
+ than or equal to any other element) that will be returned for empty collections.
669
670
670
671
!!! compat "Julia 1.6"
671
672
Keyword argument `init` requires Julia 1.6 or later.
0 commit comments