To get the smallest numeric value of an array
someArray = arrayNew(1);
writeOutput(arrayMin(someArray));
Expected Result: 0
Uses the arrayMin function to get the smallest numeric value of an array
someArray = [23,45,87,2,4];
writeOutput(arrayMin(someArray));
Expected Result: 2
CF 11+ Lucee 4.5+
someArray = [23,45,99,1,4];
writeOutput(someArray.Min());
Expected Result: 1
Signup for cfbreak to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.