A small BUG in maxmin function (PHP) is shown in the following figure:
# Psy Shell v0.3.3 (PHP 5.5.30 — cli) by Justin Hileman>>> ceil(-0.5)=> -0.0>>> max(-0.0, 0)=> 0.0>>> max(ceil(-0.5), 0)=> -0.0
In the above demonstration, the ceil function
Take a direct look at the show:
# Psy Shell v0.3.3 (PHP 5.5.30-cli) by Justin hileman>>> ceil ( -0.5) = -0.0>>> max ( -0.0, 0) = 0.0 >>> Max (Ceil ( -0.5), 0) = 0.0
In the above demo, the Ceil function returns a 0.0 when -0.0,max passes the
Max () returns the maximum value.
GrammarMax (x, y) parameter descriptionX required. A number.Y required. A number.
DescriptionMax () returns the value with the largest number in the parameter.
If there is only one parameter and an array, Max ()
Phpmax () min () returns the maximum and minimum values. Max () returns the maximum value. The max (x, y) parameter description x is required. A number. Y is required. A number. It indicates the maximum value in the return parameter of max. If there
Current number of APIs 49 common calculations (one) min-find the minimum max-find the maximum abs-absolute value round-rounding the floating-point numbers ceil-returns the smallest integer greater than or equal to the specified expression, and the
The strange problem with the PHP Array is as follows: PHPcode $ arr1 contains the data obtained from the database, and print_r is as follows: Array ([0] = & gt; 30544 [1] = & gt; 30544 [2] = & gt; 30532 [3] Strange PHP array problems
As follows:
The strange problem with the PHP Array is as follows: PHPcode $ arr1 contains the data obtained from the database, and print_r is as follows: Array ([0] & gt; 30544 [1] & gt; 30544 [2] & gt; 30532 [3] & gt; 30550 [4] & gt; 30544 [5] & gt; 30544
The strange problem with the PHP Array is as follows: PHPcode $ arr1 contains the data obtained from the database, and print_r is as follows: Array ([0] & gt; 30544 [1] & gt; 30544 [2] & gt; 30532 [3] & gt; 30550 [4] & gt; 30544 [5] & gt; strange
PHP Array Strange problem
As follows:
PHP Code
$arr 1 is the data extracted from the database, Print_r out as follows: Array ( [0] = 30544 [1] = 30544 [2] = = 30532 [3] = 30550 [4] = 30544 [5] = 30544 [6] = 30532
PHP Array Strange problem
As follows:
PHP Code
$arr 1 is the data extracted from the database, Print_r out as follows: Array ( [0] = 30544 [1] = 30544 [2] = = 30532 [3] = 30550 [4] = 30544 [5] = 30544 [6] = 30532
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.