Minimum number using min() function

MIN(value1,value2,value3 .....) 
We can get minimum value or lowest number between two variables or two numbers by using man() function. .
echo min(-5.8,5,44,-56); //Output is -56

MIN function with String

Strings are treated as 0 while comparing.
When two equal values are there the order decides which is minimum or lowest.
min('plus2net',-1);  // Output is -1
min('plus2net',0); // Output is  plus2net
min('plus2net',1); // Output is  plus2net

MIN function with Array

echo min(array(-6,8,-22,3,15,-5)); //Output is -22

Read More on max value of Array

Subscribe to our YouTube Channel here


* indicates required
Subscribe to plus2net

    Post your comments , suggestion , error , requirements etc here .

    We use cookies to improve your browsing experience. . Learn more
    HTML MySQL PHP JavaScript ASP Photoshop Articles FORUM . Contact us
    ©2000-2023 All rights reserved worldwide Privacy Policy Disclaimer