3v4l.org

run code in 300+ PHP versions simultaneously
<?php $length = 10; $width = 7; $height = 9; $array = [$length,$width,$height]; ASort($array); Echo "largest: " . $array[0] ."\n"; Echo "the other two " . $array[1] . " " . $array[2];

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.4.120.0090.01120.48
8.4.110.0120.00822.38
8.4.100.0130.00717.68
8.4.90.0100.01020.42
8.4.80.0130.00718.83
8.4.70.0090.01018.65
8.4.60.0040.00518.89
8.4.50.0100.00217.59
8.4.40.0090.00319.59
8.4.30.0100.01019.66
8.4.20.0070.01117.53
8.4.10.0100.00317.66
8.3.250.0060.00418.73
8.3.240.0130.00616.45
8.3.230.0140.00516.40
8.3.220.0090.00819.02
8.3.210.0080.01219.02
8.3.200.0030.00616.39
8.3.190.0070.01117.06
8.3.180.0080.00716.56
8.3.170.0090.00618.75
8.3.160.0140.00316.61
8.3.150.0090.00919.03
8.3.140.0070.01316.59
8.3.130.0060.00318.41
8.3.120.0090.00918.97
8.3.110.0050.00520.94
8.3.100.0080.00024.06
8.3.90.0050.00326.77
8.3.80.0090.00017.97
8.3.70.0090.00616.22
8.3.60.0070.01418.36
8.3.50.0080.01316.42
8.3.40.0110.00418.84
8.3.30.0090.00618.84
8.3.20.0070.00020.21
8.3.10.0040.00422.09
8.3.00.0040.00419.43
8.2.290.0110.00616.63
8.2.280.0040.01118.51
8.2.270.0040.00416.43
8.2.260.0070.01120.41
8.2.250.0040.00418.58
8.2.240.0120.00417.15
8.2.230.0080.00022.58
8.2.220.0080.00037.54
8.2.210.0040.00426.77
8.2.200.0030.00616.75
8.2.190.0090.00916.58
8.2.180.0100.00718.04
8.2.170.0070.01122.96
8.2.160.0100.00319.41
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0090.00926.16
8.2.120.0030.00521.07
8.2.110.0050.00522.07
8.2.100.0080.00317.72
8.2.90.0050.00317.97
8.2.80.0000.00817.97
8.2.70.0000.00817.93
8.2.60.0040.00818.16
8.2.50.0090.00618.10
8.2.40.0030.00520.46
8.2.30.0070.00019.34
8.2.20.0000.00718.00
8.2.10.0050.00218.12
8.2.00.0040.00418.11
8.1.330.0100.01016.26
8.1.320.0090.01116.08
8.1.310.0110.00416.73
8.1.300.0090.00018.62
8.1.290.0040.00430.84
8.1.280.0070.01125.92
8.1.270.0080.00024.66
8.1.260.0090.00026.35
8.1.250.0200.00028.09
8.1.240.0030.00720.39
8.1.230.0090.00321.05
8.1.220.0030.00520.93
8.1.210.0050.00318.77
8.1.200.0030.00617.13
8.1.190.0000.00817.23
8.1.180.0030.00518.10
8.1.170.0000.00718.84
8.1.160.0040.00418.82
8.1.150.0040.00418.91
8.1.140.0040.00419.57
8.1.130.0000.00720.71
8.1.120.0090.00017.51
8.1.110.0000.01117.45
8.1.100.0080.00017.43
8.1.90.0040.00417.33
8.1.80.0040.00417.42
8.1.70.0070.00017.44
8.1.60.0060.00317.53
8.1.50.0030.00517.57
8.1.40.0060.00617.42
8.1.30.0040.00417.66
8.1.20.0040.00417.61
8.1.10.0040.00417.47
8.1.00.0040.00417.48
8.0.300.0030.00621.96
8.0.290.0040.00416.75
8.0.280.0000.00718.50
8.0.270.0030.00316.80
8.0.260.0050.00218.88
8.0.250.0070.00016.96
8.0.240.0070.00016.92
8.0.230.0030.00316.86
8.0.220.0030.00316.79
8.0.210.0060.00316.88
8.0.200.0030.00316.84
8.0.190.0030.00516.82
8.0.180.0040.00416.83
8.0.170.0000.00816.81
8.0.160.0000.00716.95
8.0.150.0030.00316.79
8.0.140.0070.00016.67
8.0.130.0070.00013.30
8.0.120.0030.00616.96
8.0.110.0070.00016.92
8.0.100.0040.00416.93
8.0.90.0030.00616.89
8.0.80.0120.00416.80
8.0.70.0000.00716.78
8.0.60.0040.00416.78
8.0.50.0040.00416.68
8.0.30.0040.01517.09
8.0.20.0120.00817.42
8.0.10.0000.00816.99
8.0.00.0090.00816.79
7.4.330.0020.00215.55
7.4.320.0000.00616.64
7.4.300.0030.00316.51
7.4.290.0030.00316.52
7.4.280.0030.00516.61
7.4.270.0000.00616.54
7.4.260.0000.00816.45
7.4.250.0070.00016.45
7.4.240.0000.00816.65
7.4.230.0030.00316.30
7.4.220.0190.00616.59
7.4.210.0100.01116.45
7.4.200.0040.00416.56
7.4.160.0050.01116.52
7.4.150.0070.01017.40
7.4.140.0100.00817.86
7.4.130.0090.00916.48
7.4.120.0090.01116.47
7.4.110.0060.01116.63
7.4.100.0120.01316.45
7.4.90.0110.00616.57
7.4.80.0070.01019.39
7.4.70.0150.00616.47
7.4.60.0120.00616.64
7.4.50.0090.00616.33
7.4.40.0000.01616.33
7.4.30.0090.00616.34
7.4.00.0030.01214.75
7.3.330.0060.00013.25
7.3.320.0030.00313.00
7.3.310.0000.00916.32
7.3.300.0000.00616.36
7.3.290.0070.01016.25
7.3.280.0080.00916.29
7.3.270.0100.00717.40
7.3.260.0090.01016.44
7.3.250.0090.01016.36
7.3.240.0110.00816.44
7.3.230.0150.00316.31
7.3.210.0140.00516.46
7.3.200.0060.01016.48
7.3.190.0060.00916.39
7.3.180.0100.00716.28
7.3.170.0130.00916.43
7.3.160.0180.00316.32
7.2.330.0070.01016.50
7.2.320.0060.01216.81
7.2.310.0060.01016.61
7.2.300.0040.01916.74
7.2.290.0090.00616.38
7.2.60.0100.00317.02
7.1.200.0070.00715.57
7.1.80.0090.00917.95
7.1.70.0120.00617.01
7.1.60.0220.01235.06
7.1.50.0260.00734.48
7.1.40.0230.01634.36
7.1.30.0260.00934.54
7.1.20.0170.02034.52
7.1.10.0060.01116.59
7.1.00.0110.01016.42
7.0.200.0040.01216.84
7.0.190.0090.00916.75
7.0.180.0000.01816.27
7.0.170.0100.01116.14
7.0.160.0030.01416.00
7.0.150.0080.01416.13
7.0.140.0000.02016.34
7.0.130.0070.01416.45
7.0.120.0000.02016.42
7.0.110.0110.00916.21
7.0.100.0070.01416.36
7.0.90.0060.01616.45
7.0.80.0090.01316.39
7.0.70.0060.01416.21
7.0.60.0050.01216.25
7.0.50.0100.01416.30
7.0.40.0120.00916.58
7.0.30.0030.01716.43
7.0.20.0080.01216.51
7.0.10.0060.01316.48
7.0.00.0140.00316.36

preferences:
28.45 ms | 403 KiB | 5 Q