3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array('123', '456A', '78'); sort($a); print_r($a); $b = array('456A', '78', '123'); sort($b); print_r($b); $c = array('78', '123', '456A'); sort($c); print_r($c); $d = array('78', '456A', '123'); sort($d); print_r($d); while (list($chiave, $valore) = each($a)) { echo "A[" . $chiave . "] = " . $valore . "\n"; } while (list($chiave, $valore) = each($b)) { echo "B[" . $chiave . "] = " . $valore . "\n"; }

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.3.60.0110.01116.63
8.3.50.0090.01022.93
8.3.40.0140.00718.79
8.3.30.0070.00718.96
8.3.20.0050.00320.21
8.3.10.0080.00023.64
8.3.00.0000.00819.51
8.2.180.0100.00716.75
8.2.170.0070.00722.96
8.2.160.0090.00620.57
8.2.150.0050.00324.18
8.2.140.0040.00424.66
8.2.130.0070.01026.16
8.2.120.0050.00221.09
8.2.110.0090.00020.57
8.2.100.0040.00717.97
8.2.90.0000.00819.22
8.2.80.0040.00417.97
8.2.70.0030.00517.38
8.2.60.0090.00018.04
8.2.50.0030.00718.07
8.2.40.0000.00818.03
8.2.30.0040.00418.07
8.2.20.0050.00317.74
8.2.10.0030.00618.00
8.2.00.0000.00717.73
8.1.280.0150.00425.92
8.1.270.0030.01223.81
8.1.260.0050.00226.35
8.1.250.0070.00028.09
8.1.240.0000.00923.98
8.1.230.0090.00319.16
8.1.220.0070.00017.76
8.1.210.0040.00418.77
8.1.200.0120.00017.23
8.1.190.0040.00417.23
8.1.180.0030.00718.10
8.1.170.0100.00018.64
8.1.160.0030.00521.82
8.1.150.0000.00718.83
8.1.140.0000.00717.38
8.1.130.0070.00017.86
8.1.120.0030.00517.33
8.1.110.0040.00417.43
8.1.100.0040.00417.29
8.1.90.0030.00317.27
8.1.80.0080.00017.40
8.1.70.0050.00217.24
8.1.60.0040.00417.55
8.1.50.0080.00017.44
8.1.40.0040.00417.36
8.1.30.0050.00317.41
8.1.20.0000.00817.55
8.1.10.0000.00817.45
8.1.00.0000.00717.38
8.0.300.0030.00618.77
8.0.290.0040.00416.75
8.0.280.0040.00418.26
8.0.270.0040.00417.04
8.0.260.0060.00017.23
8.0.250.0030.00316.86
8.0.240.0060.00616.82
8.0.230.0040.00416.94
8.0.220.0030.00316.91
8.0.210.0070.00016.85
8.0.200.0000.00616.95
8.0.190.0000.00916.82
8.0.180.0000.00716.92
8.0.170.0080.00016.74
8.0.160.0050.00216.88
8.0.150.0030.00316.82
8.0.140.0080.00016.85
8.0.130.0030.00313.35
8.0.120.0040.00416.74
8.0.110.0000.00816.88
8.0.100.0050.00317.00
8.0.90.0000.00816.75
8.0.80.0180.00316.92
8.0.70.0080.00016.75
8.0.60.0070.00016.88
8.0.50.0030.00516.84
8.0.30.0070.01316.94
8.0.20.0190.00717.40
8.0.10.0000.00717.05
8.0.00.0090.00816.61
7.4.330.0050.00015.09
7.4.320.0000.00716.42
7.4.300.0000.00616.58
7.4.290.0030.00316.64
7.4.280.0000.00816.50
7.4.270.0040.00416.40
7.4.260.0000.00716.55
7.4.250.0040.00416.45
7.4.240.0040.00416.49
7.4.230.0030.00316.43
7.4.220.0030.01416.45
7.4.210.0110.00316.46
7.4.200.0070.00016.63
7.4.160.0120.00416.47
7.4.150.0140.00417.40
7.4.140.0100.00817.86
7.4.130.0120.00716.42
7.4.120.0090.00916.60
7.4.110.0130.00316.56
7.4.100.0180.00016.52
7.4.90.0170.00016.51
7.4.80.0100.01319.39
7.4.70.0130.00316.57
7.4.60.0150.00316.48
7.4.50.0000.00416.42
7.4.40.0090.00916.49
7.4.30.0060.00916.31
7.4.10.0070.01117.94
7.4.00.0060.01116.51
7.3.330.0000.00713.18
7.3.320.0030.00313.11
7.3.310.0000.00716.42
7.3.300.0000.00616.29
7.3.290.0120.00316.39
7.3.280.0060.00916.38
7.3.270.0100.00717.40
7.3.260.0100.01416.43
7.3.250.0100.00716.58
7.3.240.0040.01216.51
7.3.230.0120.00416.42
7.3.210.0140.00816.35
7.3.200.0100.01119.39
7.3.190.0100.01316.45
7.3.180.0120.00316.46
7.3.170.0090.00616.28
7.3.160.0030.01716.38
7.3.130.0180.00017.94
7.3.120.0090.00617.94
7.3.110.0000.01917.94
7.3.100.0150.00017.94
7.3.90.0040.01217.94
7.3.80.0000.00917.94
7.3.70.0090.00617.94
7.3.60.0060.00917.94
7.3.50.0090.00617.94
7.3.40.0120.00617.94
7.3.30.0040.00417.94
7.3.20.0030.00917.94
7.3.10.0040.00417.94
7.3.00.0000.00817.94
7.2.330.0080.01616.33
7.2.320.0110.00716.80
7.2.310.0100.01016.71
7.2.300.0070.01116.74
7.2.290.0080.00916.73
7.2.260.0070.01117.94
7.2.250.0070.01317.94
7.2.240.0000.01117.94
7.2.230.0000.01717.94
7.2.220.0040.01117.94
7.2.210.0040.00417.94
7.2.200.0090.00617.94
7.2.190.0100.00317.94
7.2.180.0030.01217.94
7.2.170.0100.00717.94
7.2.160.0030.00617.94
7.2.150.0090.00617.94
7.2.140.0030.00617.94
7.2.130.0000.01517.94
7.2.120.0030.00917.94
7.2.110.0030.01017.94
7.2.100.0090.00017.94
7.2.90.0030.01217.94
7.2.80.0070.00317.94
7.2.70.0140.00317.94
7.2.60.0060.00917.41
7.2.50.0030.01017.94
7.2.40.0100.00617.94
7.2.30.0030.01317.94
7.2.20.0070.00317.94
7.2.10.0000.01117.94
7.2.00.0070.00718.73
7.1.330.0070.00717.94
7.1.320.0030.01017.94
7.1.310.0090.00317.94
7.1.300.0030.00917.94
7.1.290.0090.00317.94
7.1.280.0090.00917.94
7.1.270.0030.00917.94
7.1.260.0060.00317.94
7.1.250.0070.00717.94
7.1.240.0030.00717.94
7.1.230.0100.00317.94
7.1.220.0040.00417.94
7.1.210.0000.01017.94
7.1.200.0050.00716.75
7.1.190.0100.00317.94
7.1.180.0030.01017.94
7.1.170.0040.01117.94
7.1.160.0040.01117.94
7.1.150.0000.01417.94
7.1.140.0030.01317.94
7.1.130.0090.00617.94
7.1.120.0040.00717.94
7.1.110.0070.00717.94
7.1.100.0090.00517.82
7.1.90.0040.01117.94
7.1.80.0000.01317.94
7.1.70.0030.00517.37
7.1.60.0070.00918.70
7.1.50.0080.00317.44
7.1.40.0030.01217.94
7.1.30.0030.01317.94
7.1.20.0060.00917.94
7.1.10.0000.00917.94
7.1.00.0100.03620.19
7.0.330.0040.01117.94
7.0.320.0000.00817.94
7.0.310.0060.00617.94
7.0.300.0060.00617.94
7.0.290.0030.01317.94
7.0.280.0000.00817.94
7.0.270.0030.01317.94
7.0.260.0060.00617.94
7.0.250.0030.00917.94
7.0.240.0000.01017.94
7.0.230.0060.00617.94
7.0.220.0040.00417.94
7.0.210.0000.01017.94
7.0.200.0020.00817.23
7.0.190.0060.00317.94
7.0.180.0070.00317.94
7.0.170.0030.00917.94
7.0.160.0040.00817.94
7.0.150.0070.00317.94
7.0.140.0060.03920.01
7.0.130.0050.00517.94
7.0.120.0130.00017.94
7.0.110.0030.00917.94
7.0.100.0100.04918.96
7.0.90.0040.02518.92
7.0.80.0080.04318.92
7.0.70.0050.03318.90
7.0.60.0070.04118.90
7.0.50.0090.04419.12
7.0.40.0080.04019.04
7.0.30.0090.04219.06
7.0.20.0100.03719.05
7.0.10.0020.04719.03
7.0.00.0090.04519.03
5.6.400.0140.00017.94
5.6.390.0000.01217.94
5.6.380.0040.00817.94
5.6.370.0000.00817.94
5.6.360.0040.00817.94
5.6.350.0070.00717.94
5.6.340.0030.01017.94
5.6.330.0040.01117.94
5.6.320.0040.01117.94
5.6.310.0030.01017.94
5.6.300.0000.01317.94
5.6.290.0030.01017.94
5.6.280.0000.05619.40
5.6.270.0040.00417.94
5.6.260.0000.00917.94
5.6.250.0120.03519.29
5.6.240.0100.04019.24
5.6.230.0150.02519.31
5.6.220.0100.03819.29
5.6.210.0020.04619.35
5.6.200.0040.04519.56
5.6.190.0060.04819.43
5.6.180.0050.04719.51
5.6.170.0120.04019.51
5.6.160.0070.03519.49
5.6.150.0070.03919.45
5.6.140.0100.04019.45
5.6.130.0020.04619.52
5.6.120.0080.04519.47
5.6.110.0130.04019.43
5.6.100.0150.03519.48
5.6.90.0030.04819.49
5.6.80.0070.04319.18
5.6.70.0050.04419.13
5.6.60.0030.04719.24
5.6.50.0070.04019.19
5.6.40.0110.03719.20
5.6.30.0170.03519.16
5.6.20.0070.04519.16
5.6.10.0040.04719.13
5.6.00.0050.04519.17
5.5.380.0070.04319.19
5.5.370.0170.01719.18
5.5.360.0040.04419.21
5.5.350.0120.03519.14
5.5.340.0130.04019.41
5.5.330.0070.04519.41
5.5.320.0090.04519.36
5.5.310.0050.04519.41
5.5.300.0050.03019.41
5.5.290.0050.03419.38
5.5.280.0050.03319.38
5.5.270.0070.04819.38
5.5.260.0050.04719.39
5.5.250.0100.03919.29
5.5.240.0080.03819.11
5.5.230.0080.04419.07
5.5.220.0030.04518.97
5.5.210.0160.03519.07
5.5.200.0050.04419.08
5.5.190.0070.04319.08
5.5.180.0050.02919.04
5.5.170.0000.01817.94
5.5.160.0110.03219.10
5.5.150.0040.03219.09
5.5.140.0050.03618.96
5.5.130.0100.02219.05
5.5.120.0050.04019.07
5.5.110.0100.04119.04
5.5.100.0030.03219.04
5.5.90.0050.02819.00
5.5.80.0080.04218.96
5.5.70.0120.02218.96
5.5.60.0070.03618.93
5.5.50.0050.04419.02
5.5.40.0070.03018.97
5.5.30.0050.04618.99
5.5.20.0050.03218.99
5.5.10.0070.03319.01
5.5.00.0090.04018.98
5.4.450.0070.04218.74
5.4.440.0100.04018.70
5.4.430.0080.04118.65
5.4.420.0020.02818.64
5.4.410.0000.04718.63
5.4.400.0070.04318.49
5.4.390.0110.03518.49
5.4.380.0030.02918.49
5.4.370.0110.03818.42
5.4.360.0110.03618.57
5.4.350.0080.03618.39
5.4.340.0050.04018.55
5.4.330.0070.00417.94
5.4.320.0020.04318.42
5.4.310.0030.04018.44
5.4.300.0110.03518.42
5.4.290.0010.04518.49
5.4.280.0060.02518.53
5.4.270.0030.04218.58
5.4.260.0030.04018.41
5.4.250.0090.03918.39
5.4.240.0020.03918.54
5.4.230.0060.04218.40
5.4.220.0070.03718.53
5.4.210.0070.03918.48
5.4.200.0080.03218.44
5.4.190.0060.04118.55
5.4.180.0080.03018.55
5.4.170.0080.03518.41
5.4.160.0050.04218.53
5.4.150.0040.05018.47
5.4.140.0030.04017.20
5.4.130.0070.03017.19
5.4.120.0100.03517.20
5.4.110.0120.03317.20
5.4.100.0050.04117.20
5.4.90.0090.03517.20
5.4.80.0070.03217.17
5.4.70.0070.03317.16
5.4.60.0050.04017.19
5.4.50.0030.04017.12
5.4.40.0020.04317.18
5.4.30.0080.03317.12
5.4.20.0030.04517.13
5.4.10.0030.02217.20
5.4.00.0040.02116.92
5.3.290.0070.06014.62
5.3.280.0070.08014.60
5.3.270.0030.07014.59
5.3.260.0030.06314.63
5.3.250.0130.06714.66
5.3.240.0100.07714.58
5.3.230.0030.07714.52
5.3.220.0070.07714.63
5.3.210.0100.08014.54
5.3.200.0070.05714.49
5.3.190.0170.04014.70
5.3.180.0000.05014.69
5.3.170.0070.07314.70
5.3.160.0030.06314.54
5.3.150.0030.07314.51
5.3.140.0130.06314.56
5.3.130.0100.06314.50
5.3.120.0130.07714.54
5.3.110.0070.07014.65
5.3.100.0100.07714.01
5.3.90.0130.07014.15
5.3.80.0030.04313.90
5.3.70.0070.06014.05
5.3.60.0030.06014.00
5.3.50.0030.05714.05
5.3.40.0070.06014.01
5.3.30.0030.03313.89
5.3.20.0070.07013.75
5.3.10.0070.07713.66
5.3.00.0070.05013.70
5.2.170.0030.03711.27
5.2.160.0130.05011.27
5.2.150.0100.04311.13
5.2.140.0030.05711.24
5.2.130.0070.05711.20
5.2.120.0070.05311.10
5.2.110.0100.05311.22
5.2.100.0000.03011.22
5.2.90.0030.05011.19
5.2.80.0030.03310.98
5.2.70.0100.05011.02
5.2.60.0070.07011.17
5.2.50.0100.05311.11
5.2.40.0070.03310.88
5.2.30.0070.05310.91
5.2.20.0000.04310.87
5.2.10.0070.05710.89
5.2.00.0200.04010.70
5.1.60.0100.04710.05
5.1.50.0070.05310.03
5.1.40.0130.0409.89
5.1.30.0000.05010.45
5.1.20.0070.05710.32
5.1.10.0070.03310.15
5.1.00.0100.05010.06
5.0.50.0030.0479.89
5.0.40.0000.0509.89
5.0.30.0030.0609.89
5.0.20.0100.0379.89
5.0.10.0000.0339.89
5.0.00.0070.0539.89
4.4.90.0000.0339.89
4.4.80.0000.0179.89
4.4.70.0030.0339.89
4.4.60.0030.0309.89
4.4.50.0000.0179.89
4.4.40.0000.0539.89
4.4.30.0000.0409.89
4.4.20.0030.0239.89
4.4.10.0000.0209.89
4.4.00.0000.0379.89
4.3.110.0030.0339.89
4.3.100.0030.0309.89
4.3.90.0030.0209.89
4.3.80.0000.0509.89
4.3.70.0030.0279.89
4.3.60.0000.0379.89
4.3.50.0100.0179.89
4.3.40.0000.0509.89
4.3.30.0030.0339.89
4.3.20.0030.0379.89
4.3.10.0000.0209.89
4.3.00.0030.0209.89

preferences:
38.36 ms | 401 KiB | 5 Q