Minimum value in a range

Andrej Mitrovic andrej.mitrovich at gmail.com
Tue Aug 2 05:03:22 PDT 2011


import std.algorithm;

void main()
{
    auto x = min([1, 2, 3]);  // x would be 1
}

min() isn't equipped to do this on a single range. What can I use
instead? I haven't had my coffee yet. :)


More information about the Digitalmars-d-learn mailing list