Perhaps this doesn't belong here, but I was using maxBy and minBy and noticed something a little surprising. If there are duplicate max values, only one is returned, with no warning.
i.e. [|(1,'a');(2,'b');(2,'c')|] |> Array.maxBy fst
= (2,'b')
Perhaps it should just return 2, or an array, or a result<'a,'a[]>, but as it stands, I think the current behavior is a bit surprising.
Perhaps this doesn't belong here, but I was using maxBy and minBy and noticed something a little surprising. If there are duplicate max values, only one is returned, with no warning.
i.e. [|(1,'a');(2,'b');(2,'c')|] |> Array.maxBy fst
= (2,'b')
Perhaps it should just return 2, or an array, or a result<'a,'a[]>, but as it stands, I think the current behavior is a bit surprising.