3v4l.org

run code in 300+ PHP versions simultaneously
<?php $schema = Array( Array("prestation_1" => 123, "prestataire_1" => 321, "prestation_2" => 456, "prestataire_2" => 654), Array("prestation_1" => 123, "prestataire_1" => 321, "prestation_2" => 456, "prestataire_2" => 654), Array("prestation_1" => 123, "prestataire_1" => 321, "prestation_2" => 456, "prestataire_2" => 654), Array("prestation_1" => 123, "prestataire_1" => 321, "prestation_2" => 456, "prestataire_2" => 654) ); function check( $array) { $array=array_values($array); $k=0; for($i=0;$i<count($array);$i++) { if(count($array)-1 > $i) { if($array[$i] == $array[$i]) $k=0; else $k=1; } } if($k == 0) return $array[0]; else return array(); } print_r(check($schema)) ;

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.40.0040.01118.79
8.3.30.0090.00918.89
8.3.20.0050.00320.16
8.3.10.0080.00021.97
8.3.00.0060.00322.57
8.2.170.0110.00322.96
8.2.160.0030.01020.28
8.2.150.0040.00424.18
8.2.140.0030.00724.66
8.2.130.0000.00826.16
8.2.120.0000.00819.79
8.2.110.0070.01520.57
8.2.100.0110.00018.03
8.2.90.0000.00819.15
8.2.80.0040.00417.97
8.2.70.0050.00517.50
8.2.60.0060.00318.16
8.2.50.0060.00318.07
8.2.40.0000.00718.09
8.2.30.0000.00718.18
8.2.20.0000.00717.61
8.2.10.0040.00417.66
8.2.00.0000.00817.74
8.1.270.0100.00320.30
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0050.00822.12
8.1.230.0000.01220.84
8.1.220.0050.00317.78
8.1.210.0080.00018.77
8.1.200.0060.00317.13
8.1.190.0050.00317.18
8.1.180.0050.00318.60
8.1.170.0000.00818.45
8.1.160.0030.00522.14
8.1.150.0050.00618.68
8.1.140.0000.00717.45
8.1.130.0070.00017.75
8.1.120.0070.00017.36
8.1.110.0000.00817.28
8.1.100.0000.00717.44
8.1.90.0050.00317.48
8.1.80.0000.00717.33
8.1.70.0040.00417.37
8.1.60.0040.00417.57
8.1.50.0000.00717.46
8.1.40.0090.00017.45
8.1.30.0040.00417.64
8.1.20.0040.00417.68
8.1.10.0060.00317.46
8.1.00.0050.00517.38
8.0.300.0000.00718.77
8.0.290.0070.00017.05
8.0.280.0030.00318.36
8.0.270.0040.00417.32
8.0.260.0030.00316.73
8.0.250.0070.00016.87
8.0.240.0040.00416.96
8.0.230.0030.00316.90
8.0.220.0070.00016.91
8.0.210.0070.00016.90
8.0.200.0000.00616.94
8.0.190.0000.00816.99
8.0.180.0050.00316.95
8.0.170.0070.00016.91
8.0.160.0060.00316.75
8.0.150.0070.00016.86
8.0.140.0000.00716.76
8.0.130.0000.00513.39
8.0.120.0000.00716.78
8.0.110.0000.00716.91
8.0.100.0030.00316.82
8.0.90.0070.00016.88
8.0.80.0100.00716.93
8.0.70.0000.00716.69
8.0.60.0000.00716.78
8.0.50.0000.00716.86
8.0.30.0090.00917.27
8.0.20.0080.01017.40
8.0.10.0000.00717.02
8.0.00.0090.01216.75
7.4.330.0000.00515.00
7.4.320.0000.00616.62
7.4.300.0030.00316.59
7.4.290.0030.00316.50
7.4.280.0060.00016.43
7.4.270.0040.00416.52
7.4.260.0000.00716.54
7.4.250.0000.00716.55
7.4.240.0050.00216.51
7.4.230.0030.00316.62
7.4.220.0130.00916.54
7.4.210.0090.00816.62
7.4.200.0000.00716.34
7.4.190.0040.00416.69
7.4.160.0080.00816.59
7.4.150.0160.00717.40
7.4.140.0070.01217.86
7.4.130.0120.00816.57
7.4.120.0130.00516.44
7.4.110.0150.00616.59
7.4.100.0100.00716.43
7.4.90.0130.00616.38
7.4.80.0050.01219.39
7.4.70.0080.01116.52
7.4.60.0100.00616.50
7.4.50.0030.00516.34
7.4.40.0030.00922.77
7.4.30.0130.00416.52
7.4.00.0000.01114.91
7.3.330.0050.00013.24
7.3.320.0000.00513.08
7.3.310.0040.00416.27
7.3.300.0000.00716.24
7.3.290.0040.01116.33
7.3.280.0090.01116.29
7.3.270.0070.01017.40
7.3.260.0080.01216.42
7.3.250.0070.00916.54
7.3.240.0070.01116.47
7.3.230.0130.00516.56
7.3.210.0130.00316.61
7.3.200.0030.01419.39
7.3.190.0090.01216.55
7.3.180.0070.01116.23
7.3.170.0140.00916.35
7.3.160.0110.01116.56
7.3.120.0090.00915.19
7.2.330.0130.01316.75
7.2.320.0120.00916.50
7.2.310.0070.01116.45
7.2.300.0100.00716.92
7.2.290.0090.01216.51
7.2.00.0060.00619.39
7.1.100.0030.00618.17
7.1.70.0000.00916.85
7.1.60.0140.01019.82
7.1.50.0040.00716.85
7.1.00.0030.07322.54
7.0.200.0040.01116.82
7.0.140.0100.06721.96
7.0.60.0070.08019.86
7.0.50.0030.04717.88
7.0.40.0130.07020.30
7.0.30.0300.04320.12
7.0.20.0400.06320.22
7.0.10.0130.08320.12
7.0.00.0170.05320.24
5.6.280.0030.07321.10
5.6.210.0030.06320.75
5.6.200.0030.04018.19
5.6.190.0130.08020.57
5.6.180.0330.07020.67
5.6.170.0430.06720.71
5.6.160.0030.09020.50
5.6.150.0100.07718.14
5.6.140.0030.06018.27
5.6.130.0130.07018.20
5.6.120.0030.08720.90
5.6.110.0100.07021.01
5.6.100.0030.04721.00
5.6.90.0100.08020.99
5.6.80.0070.07020.43
5.5.350.0000.08020.30
5.5.340.0070.08017.95
5.5.330.0100.08020.37
5.5.320.0300.05320.34
5.5.310.0270.03320.34
5.5.300.0100.07718.06
5.5.290.0030.08717.95
5.5.280.0030.04320.80
5.5.270.0100.08020.77
5.5.260.0100.04320.88
5.5.250.0100.09320.78
5.5.240.0270.04720.23
5.4.450.0770.03719.16
5.4.440.0830.06319.68
5.4.430.0700.05719.55
5.4.420.1000.06319.59
5.4.410.0970.05019.22
5.4.400.0670.05018.89
5.4.390.0770.06019.02
5.4.380.0370.04318.56
5.4.370.0170.05318.70
5.4.360.0230.04318.82
5.4.350.0110.04712.02
5.4.340.0100.04512.02
5.4.320.0050.03712.50
5.4.310.0060.04212.50
5.4.300.0070.04312.50
5.4.290.0060.03912.50
5.4.280.0040.05012.40
5.4.270.0060.04412.40
5.4.260.0050.04112.40
5.4.250.0030.05718.97
5.4.240.0130.05018.97
5.4.230.0100.04718.94
5.4.220.0070.05318.97
5.4.210.0100.05019.12
5.4.200.0130.05318.66
5.4.190.0100.05018.84
5.4.180.0070.05318.95
5.4.170.0130.04718.89
5.4.160.0100.04718.99
5.4.150.0100.05018.95
5.4.140.0100.05316.39
5.4.130.0170.06716.59
5.4.120.0130.04316.40
5.4.110.0070.05316.50
5.4.100.0000.05316.41
5.4.90.0030.05016.48
5.4.80.0130.04016.52
5.4.70.0030.05316.48
5.4.60.0030.05316.36
5.4.50.0100.04716.47
5.4.40.0030.05316.57
5.4.30.0070.06016.44
5.4.20.0030.05016.63
5.4.10.0030.05716.36
5.4.00.0070.05016.04
5.3.290.0040.04612.80
5.3.280.0000.05314.73
5.3.270.0130.06014.83
5.3.260.0100.04714.44
5.3.250.0130.04314.78
5.3.240.0100.05014.69
5.3.230.0130.05314.60
5.3.220.0100.05314.75
5.3.210.0070.05014.63
5.3.200.0000.05314.58
5.3.190.0130.04314.55
5.3.180.0130.04314.54
5.3.170.0030.05314.63
5.3.160.0100.04714.78
5.3.150.0070.05314.65
5.3.140.0000.05314.55
5.3.130.0070.05314.47
5.3.120.0070.05314.63
5.3.110.0070.05014.52
5.3.100.0130.04314.02
5.3.90.0170.04014.12
5.3.80.0000.05713.93
5.3.70.0100.05014.04
5.3.60.0030.05014.08
5.3.50.0100.04314.04
5.3.40.0130.04314.04
5.3.30.0070.04713.88
5.3.20.0100.04313.79
5.3.10.0030.05013.73
5.3.00.0070.05013.66
5.2.170.0030.04011.32
5.2.160.0100.03711.30
5.2.150.0070.04011.22
5.2.140.0070.04011.30
5.2.130.0100.03711.28
5.2.120.0130.03011.01
5.2.110.0070.03711.17
5.2.100.0130.04011.17
5.2.90.0070.03711.27
5.2.80.0030.04011.31
5.2.70.0070.04011.16
5.2.60.0100.05011.14
5.2.50.0000.04311.10
5.2.40.0030.04010.98
5.2.30.0070.04011.04
5.2.20.0000.04711.02
5.2.10.0030.04011.04
5.2.00.0030.04010.68
5.1.60.0100.03710.05
5.1.50.0000.03710.15
5.1.40.0030.0339.82
5.1.30.0030.03710.41
5.1.20.0030.04010.53
5.1.10.0070.03010.06
5.1.00.0030.03310.02
5.0.50.0000.0338.63
5.0.40.0030.0278.45
5.0.30.0000.0438.38
5.0.20.0070.0238.43
5.0.10.0030.0308.27
5.0.00.0030.0408.20
4.4.90.0030.0306.96
4.4.80.0000.0236.96
4.4.70.0070.0176.96
4.4.60.0000.0236.96
4.4.50.0000.0306.96
4.4.40.0030.0376.96
4.4.30.0000.0236.96
4.4.20.0000.0236.96
4.4.10.0070.0176.96
4.4.00.0030.0306.96
4.3.110.0070.0206.96
4.3.100.0030.0206.96
4.3.90.0070.0176.96
4.3.80.0000.0336.96
4.3.70.0000.0236.96
4.3.60.0030.0206.96
4.3.50.0000.0236.96
4.3.40.0000.0336.96
4.3.30.0000.0236.96
4.3.20.0000.0236.96
4.3.10.0030.0206.96
4.3.00.0100.0208.11

preferences:
38.39 ms | 400 KiB | 5 Q