Performance optimization for minElement and maxElement
H. S. Teoh
hsteoh at qfbox.info
Mon Sep 12 11:07:24 UTC 2022
On Sun, Sep 11, 2022 at 07:40:35PM -0700, Ali Çehreli via Digitalmars-d wrote:
> Since the minimum and maximum values of fundamental types are known, can
> minElement and maxElement shortcut and return that value immediately?
No, because that value may not appear in the given range.
T
--
Having a smoking section in a restaurant is like having a peeing section in a swimming pool. -- Edward Burr
More information about the Digitalmars-d
mailing list