3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<html> <body> <?php $arrays = array("generate "," unique "," to "," numbers "," within "," a "); $arrays_1 = array_map('strlen', $my_array); echo "The shortest array length is " . min($arrays_1) . ". The longest array length is " . max($arrays_1).'.'; ?> </html> </body>
based on i4HV4
Output for 5.3.0 - 5.6.28, 7.0.0 - 7.1.0
<html> <body> Notice: Undefined variable: my_array in /in/khf82 on line 5 Warning: array_map(): Argument #2 should be an array in /in/khf82 on line 5 Warning: min(): When only one parameter is given, it must be an array in /in/khf82 on line 6 Warning: max(): When only one parameter is given, it must be an array in /in/khf82 on line 7 The shortest array length is . The longest array length is . </html> </body>
Output for hhvm-3.10.0 - 3.12.0
<html> <body> Notice: Undefined variable: my_array in /in/khf82 on line 5 Warning: array_map(): Argument #2 should be an array or collection Warning: min(): When only one parameter is given, it must be an array in /in/khf82 on line 6 Warning: max(): When only one parameter is given, it must be an array in /in/khf82 on line 7 The shortest array length is . The longest array length is . </html> </body>
Output for 5.0.4 - 5.2.17
<html> <body> Notice: Undefined variable: my_array in /in/khf82 on line 5 Warning: array_map(): Argument #2 should be an array in /in/khf82 on line 5 Warning: Wrong parameter count for min() in /in/khf82 on line 6 Warning: Wrong parameter count for max() in /in/khf82 on line 7 The shortest array length is . The longest array length is . </html> </body>
Output for 4.3.2 - 5.0.3
<html> <body> Notice: Undefined variable: my_array in /in/khf82 on line 5 Warning: array_map(): Argument #2 should be an array in /in/khf82 on line 5 Warning: Wrong parameter count for min() in /in/khf82 on line 6 Warning: Wrong parameter count for max() in /in/khf82 on line 7 The shortest array length is . The longest array length is . </html> </body>
Output for 4.3.0 - 4.3.1
<html> <body> Notice: Undefined variable: my_array in /in/khf82 on line 5 Warning: array_map() [http://www.php.net/function.array-map]: Argument #2 should be an array in /in/khf82 on line 5 Warning: Wrong parameter count for min() in /in/khf82 on line 6 Warning: Wrong parameter count for max() in /in/khf82 on line 7 The shortest array length is . The longest array length is . </html> </body>