3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array(); $arr["TextosCodificados"]["TextoCodificado"]["0"]["QualificadorAssunto"]["0"] = "ALL"; $arr["TextosCodificados"]["TextoCodificado"]["0"]["Texto"] = "Vnd mer.adq.rec.ter.op.mer.sj.rg.sub.trb.cnd.sub.t"; $arr["TextosCodificados"]["TextoCodificado"]["1"]["QualificadorAssunto"]["0"] = "AAI"; $arr["TextosCodificados"]["TextoCodificado"]["1"]["Texto"] = "Protocolo ICMS 18809 e 1192012 ICMS Retido Art 313W"; $arr["TextosCodificados"]["TextoCodificado"]["2"]["QualificadorAssunto"]["0"] = "IVN"; $arr["TextosCodificados"]["TextoCodificado"]["2"]["Texto"] = "Pedido Interno:0000283278 ID da Carga:"; function teste($arr) { $ret = array() ; foreach($arr as $k => $v) { if(is_array($v)){ $ret.push(teste($v)); } else { $ret.push(array($k => $v)); //var_dump($k.' - '.$v); } } return $ret; } $rst = teste($arr); var_dump($rst);

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.0090.00616.63
8.3.50.0070.01316.65
8.3.40.0120.00318.68
8.3.30.0120.00318.79
8.3.20.0080.00020.34
8.3.10.0000.00821.73
8.3.00.0100.00019.78
8.2.180.0070.01417.00
8.2.170.0090.00622.96
8.2.160.0100.00320.39
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0070.00021.00
8.2.120.0000.00826.35
8.2.110.0030.00621.00
8.2.100.0060.00618.09
8.2.90.0050.00319.19
8.2.80.0000.00818.04
8.2.70.0040.00717.75
8.2.60.0000.00817.93
8.2.50.0000.00818.15
8.2.40.0030.00620.64
8.2.30.0030.00521.04
8.2.20.0000.00718.02
8.2.10.0030.00518.01
8.2.00.0070.00018.13
8.1.280.0100.00725.92
8.1.270.0080.00022.19
8.1.260.0040.00426.35
8.1.250.0000.00728.09
8.1.240.0030.00723.89
8.1.230.0040.00819.14
8.1.220.0000.00817.79
8.1.210.0030.00618.77
8.1.200.0060.00317.48
8.1.190.0040.00417.35
8.1.180.0000.00818.10
8.1.170.0110.00018.47
8.1.160.0040.00418.98
8.1.150.0050.00318.92
8.1.140.0000.00819.57
8.1.130.0000.00718.78
8.1.120.0070.00017.52
8.1.110.0000.00817.43
8.1.100.0070.00017.47
8.1.90.0040.00817.50
8.1.80.0000.00717.47
8.1.70.0030.00517.48
8.1.60.0090.00017.49
8.1.50.0000.00717.54
8.1.40.0000.00817.56
8.1.30.0000.00817.52
8.1.20.0000.00817.64
8.1.10.0060.00317.53
8.1.00.0000.00817.53
8.0.300.0000.00718.77
8.0.290.0000.00816.75
8.0.280.0000.00718.45
8.0.270.0030.00317.34
8.0.260.0030.00316.90
8.0.250.0030.00316.93
8.0.240.0040.00817.05
8.0.230.0060.00317.02
8.0.220.0000.00616.86
8.0.210.0000.00716.98
8.0.200.0000.00716.98
8.0.190.0040.00417.05
8.0.180.0000.00816.89
8.0.170.0000.00816.92
8.0.160.0060.00316.86
8.0.150.0070.00016.90
8.0.140.0000.00716.97
8.0.130.0050.00013.41
8.0.120.0050.00316.85
8.0.110.0000.00817.01
8.0.100.0040.00416.95
8.0.90.0070.00016.98
8.0.80.0060.00916.91
8.0.70.0070.00017.02
8.0.60.0040.00416.91
8.0.50.0000.00816.91
8.0.30.0090.00917.13
8.0.20.0090.00917.40
8.0.10.0040.00416.96
8.0.00.0100.01016.86
7.4.330.0060.00015.55
7.4.320.0060.00016.61
7.4.300.0000.00616.53
7.4.290.0050.00316.52
7.4.280.0040.00416.59
7.4.270.0030.00316.63
7.4.260.0030.00313.32
7.4.250.0050.00216.59
7.4.240.0040.00416.45
7.4.230.0000.00616.63
7.4.220.0030.01816.47
7.4.210.0090.00816.63
7.4.200.0050.00316.50
7.4.160.0080.00816.62
7.4.150.0170.00417.40
7.4.140.0100.00917.86
7.4.130.0130.00316.46
7.4.120.0060.01316.60
7.4.110.0030.01616.42
7.4.100.0030.01416.43
7.4.90.0090.00816.36
7.4.80.0080.00819.39
7.4.70.0060.01116.52
7.4.60.0150.00016.67
7.4.50.0120.00216.54
7.4.40.0090.00616.66
7.4.30.0130.00316.38
7.4.00.0070.01114.73
7.3.330.0000.00713.39
7.3.320.0030.00313.47
7.3.310.0030.00316.48
7.3.300.0040.00416.41
7.3.290.0030.00316.31
7.3.280.0080.00816.43
7.3.270.0110.00717.40
7.3.260.0110.00916.59
7.3.250.0070.01216.49
7.3.240.0080.00916.50
7.3.230.0090.00916.45
7.3.210.0060.01216.62
7.3.200.0060.01216.39
7.3.190.0070.01316.57
7.3.180.0130.00316.43
7.3.170.0100.01016.64
7.3.160.0080.00816.54
7.3.120.0110.00515.05
7.3.110.0090.00814.97
7.3.100.0030.01014.90
7.3.90.0020.01514.99
7.3.80.0040.01214.97
7.3.70.0060.00814.82
7.3.60.0050.00514.97
7.3.50.0030.01015.01
7.3.40.0050.00914.85
7.3.30.0050.01014.74
7.3.20.0030.01116.64
7.3.10.0020.01116.79
7.3.00.0090.00216.50
7.2.330.0090.01316.70
7.2.320.0120.00616.80
7.2.310.0000.01616.47
7.2.300.0070.01016.71
7.2.290.0000.01616.43
7.2.250.0110.00715.23
7.2.240.0080.00815.10
7.2.230.0060.00515.19
7.2.220.0080.00315.15
7.2.210.0060.00715.07
7.2.200.0090.00414.95
7.2.190.0060.00715.14
7.2.180.0070.00614.97
7.2.170.0060.00815.09
7.2.160.0000.01614.92
7.2.150.0000.01716.84
7.2.140.0040.01116.92
7.2.130.0100.00717.08
7.2.120.0000.01716.84
7.2.110.0110.00416.80
7.2.100.0100.00716.86
7.2.90.0030.01316.87
7.2.80.0060.00916.93
7.2.70.0110.00416.91
7.2.60.0050.00816.89
7.2.50.0070.01016.82
7.2.40.0030.01416.96
7.2.30.0060.00916.93
7.2.20.0100.00316.70
7.2.10.0120.00316.75
7.2.00.0040.01018.12
7.1.330.0040.01015.79
7.1.320.0070.00415.81
7.1.310.0050.00615.74
7.1.300.0050.00815.80
7.1.290.0110.00415.80
7.1.280.0040.00815.83
7.1.270.0040.00815.72
7.1.260.0050.00915.58
7.1.250.0030.01415.74
7.1.200.0030.01015.80
7.1.100.0100.00317.99
7.1.70.0030.00917.20
7.1.60.0140.01434.82
7.1.50.0170.01034.79
7.1.40.0130.01334.30
7.1.30.0200.01034.33
7.1.20.0180.00934.67
7.1.10.0000.01316.76
7.1.00.0110.00316.68
7.0.200.0000.01116.70
7.0.190.0000.01216.68
7.0.180.0110.00316.20
7.0.170.0060.00616.06
7.0.160.0050.00816.35
7.0.150.0050.00816.43
7.0.140.0040.01116.20
7.0.130.0060.00916.59
7.0.120.0090.00616.43
7.0.110.0000.01716.61
7.0.100.0030.01416.33
7.0.90.0100.00616.28
7.0.80.0120.00916.47
7.0.70.0060.01316.25
7.0.60.0030.01516.00
7.0.50.0040.01216.29
7.0.40.0030.01816.41
7.0.30.0100.00816.43
7.0.20.0070.01416.43
7.0.10.0030.01716.23
7.0.00.0040.01216.49

preferences:
53.94 ms | 401 KiB | 5 Q