3v4l.org

run code in 300+ PHP versions simultaneously
<?php // words inside string with umlaute, later add http://zahnstocher47.de instead of "zahnstocher" as the correct solution $string = "apfelsaft siebenundvierzig zahnstocher gelb ethereum österreich"; // get length of string $l = mb_strlen($string); $chars = mb_str_split($string); $f = ''; // loop through length and output each letter by itself for ($i = 0; $i <= $l; $i++){ // umlaute buggy when there is a concatenation $f .= $chars[$i] . " "; } var_dump($f);

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.1rc30.0100.00516.72
8.1rc20.0110.00416.75
8.1rc10.0110.00716.69
8.0.130.0120.00316.70
8.0.120.0130.00516.71
8.0.110.0140.00416.70
8.0.100.0140.00516.71
8.0.90.0150.00416.69
8.0.80.0160.00416.73
8.0.70.0140.00616.66
8.0.60.0140.00616.60
8.0.50.0150.00516.64
8.0.30.0160.00416.62
8.0.20.0130.00616.73
8.0.10.0150.00516.70
8.0.00.0090.00316.71
7.4.260.0120.00516.23
7.4.250.0170.00415.85
7.4.240.0190.00416.19
7.4.230.0170.00616.23
7.4.220.0150.00416.25
7.4.210.0140.00516.26
7.4.200.0140.00616.25
7.4.190.0160.00416.28
7.4.180.0150.00516.25
7.4.160.0130.00616.25
7.4.150.0160.00416.17
7.4.140.0150.00416.23
7.4.130.0160.00416.19
7.4.120.0130.00616.22
7.4.110.0140.00516.19
7.4.100.0150.00416.25
7.4.90.0130.00616.19
7.4.80.0150.00516.21
7.4.70.0160.00316.22
7.4.60.0140.00516.22
7.4.50.0150.00516.09
7.4.40.0140.00516.12
7.4.30.0150.00516.21
7.4.20.0150.00416.22
7.4.10.0150.00416.18
7.4.00.0150.00416.23
7.3.330.0070.00316.22
7.3.320.0170.00315.97
7.3.310.0170.00416.03
7.3.300.0150.00516.02
7.3.290.0160.00416.00
7.3.280.0170.00415.95
7.3.270.0160.00515.97
7.3.260.0140.00615.99
7.3.250.0160.00415.94
7.3.240.0160.00415.98
7.3.230.0150.00416.04
7.3.220.0150.00415.91
7.3.210.0150.00515.89
7.3.200.0140.00415.92
7.3.190.0150.00515.93
7.3.180.0170.00315.94
7.3.170.0140.00415.98
7.3.160.0140.00515.96
7.3.150.0140.00315.92
7.3.140.0120.00515.98
7.3.130.0140.00415.93
7.3.120.0120.00515.92
7.3.110.0140.00415.87
7.3.100.0150.00315.79
7.3.90.0130.00516.22
7.3.80.0140.00415.97
7.3.70.0100.00615.92
7.3.60.0110.00616.04
7.3.50.0120.00515.99
7.3.40.0120.00515.99
7.3.30.0120.00416.04
7.3.20.0110.00517.87
7.3.10.0120.00417.80
7.3.00.0130.00417.78

preferences:
12.3 ms | 455 KiB | 5 Q