3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array(); $arr["Intercambio"]["0"]["Versao"]["0"] = "2"; $arr["Intercambio"]["0"]["TipoIdentificacaoRemetente"]["0"] = "cnpj"; $arr["Intercambio"]["0"]["IdentificacaoRemetente"]["0"] = "02089969001420"; $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) { $newArr = array(); foreach( $arr as $k => $v ) { if( is_array($v) && count($v) == 1 ) { var_dump($k); $newArr[$k] = $v; } elseif( is_array($v) && count($v) > 1 ) { //$newArr = array_merge($newArr, teste($v)); } } return $newArr; } $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.0110.01116.48
8.3.50.0140.00716.40
8.3.40.0110.00718.75
8.3.30.0120.00318.66
8.3.20.0120.00320.21
8.3.10.0070.00021.82
8.3.00.0040.00419.51
8.2.180.0070.01118.18
8.2.170.0000.01422.96
8.2.160.0070.00720.45
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0050.00321.13
8.2.120.0000.00826.35
8.2.110.0100.00021.02
8.2.100.0070.00318.22
8.2.90.0000.00819.17
8.2.80.0090.00018.04
8.2.70.0090.00017.75
8.2.60.0000.00818.03
8.2.50.0050.00318.10
8.2.40.0030.00620.47
8.2.30.0000.00820.96
8.2.20.0070.00018.05
8.2.10.0060.00318.20
8.2.00.0030.00518.11
8.1.280.0070.00725.92
8.1.270.0050.00322.20
8.1.260.0040.00426.35
8.1.250.0000.00728.09
8.1.240.0060.00323.97
8.1.230.0040.00719.09
8.1.220.0030.00517.75
8.1.210.0040.00418.77
8.1.200.0030.00617.35
8.1.190.0030.00517.35
8.1.180.0040.00418.10
8.1.170.0040.00418.64
8.1.160.0030.00318.96
8.1.150.0040.00420.58
8.1.140.0030.00519.51
8.1.130.0100.00018.83
8.1.120.0030.00717.51
8.1.110.0000.00717.50
8.1.100.0000.00717.39
8.1.90.0000.00917.38
8.1.80.0040.00417.46
8.1.70.0070.00017.52
8.1.60.0000.00917.50
8.1.50.0040.00417.60
8.1.40.0000.00817.54
8.1.30.0060.00317.66
8.1.20.0000.00817.67
8.1.10.0000.00717.55
8.1.00.0040.00417.33
8.0.300.0000.00718.77
8.0.290.0080.00016.75
8.0.280.0000.00718.41
8.0.270.0030.00317.33
8.0.260.0070.00016.76
8.0.250.0070.00016.98
8.0.240.0000.00717.01
8.0.230.0030.00316.85
8.0.220.0000.00816.86
8.0.210.0030.00316.94
8.0.200.0030.00316.85
8.0.190.0040.00416.87
8.0.180.0000.01016.78
8.0.170.0060.00316.97
8.0.160.0040.00416.82
8.0.150.0030.00716.85
8.0.140.0000.00816.88
8.0.130.0000.00713.34
8.0.120.0070.00016.85
8.0.110.0040.00416.98
8.0.100.0040.00416.81
8.0.90.0070.00016.79
8.0.80.0080.00816.95
8.0.70.0000.00716.79
8.0.60.0000.00716.75
8.0.50.0040.00416.77
8.0.30.0100.00717.29
8.0.20.0100.00817.40
8.0.10.0040.00416.97
8.0.00.0070.01016.96
7.4.330.0000.00515.55
7.4.320.0040.00416.57
7.4.300.0000.00716.48
7.4.290.0030.00316.54
7.4.280.0080.00016.43
7.4.270.0050.00316.56
7.4.260.0040.00416.66
7.4.250.0040.00416.50
7.4.240.0000.00816.60
7.4.230.0040.00416.46
7.4.220.0060.01316.66
7.4.210.0070.00816.58
7.4.200.0040.00416.61
7.4.160.0030.01316.53
7.4.150.0140.00417.40
7.4.140.0060.01117.86
7.4.130.0070.01016.43
7.4.120.0110.00916.52
7.4.110.0060.01616.52
7.4.100.0090.01016.44
7.4.90.0100.00716.54
7.4.80.0070.01019.39
7.4.70.0100.00616.41
7.4.60.0120.00416.46
7.4.50.0070.00716.58
7.4.40.0090.01216.60
7.4.30.0100.01316.48
7.4.00.0040.00714.68
7.3.330.0030.00313.32
7.3.320.0030.00313.36
7.3.310.0040.00416.29
7.3.300.0060.00016.39
7.3.290.0000.00716.34
7.3.280.0090.00716.39
7.3.270.0150.00717.40
7.3.260.0080.00816.45
7.3.250.0100.00816.50
7.3.240.0060.01116.40
7.3.230.0030.01416.59
7.3.210.0060.01016.38
7.3.200.0060.00916.54
7.3.190.0090.01016.57
7.3.180.0090.00616.41
7.3.170.0030.01316.42
7.3.160.0110.00516.54
7.3.10.0040.01516.63
7.3.00.0090.01216.41
7.2.330.0130.00816.63
7.2.320.0060.00916.81
7.2.310.0070.01416.80
7.2.300.0140.00716.79
7.2.290.0030.01416.80
7.2.130.0100.00516.82
7.2.120.0120.00816.60
7.2.110.0150.00316.64
7.2.100.0140.00716.47
7.2.90.0060.02016.38
7.2.80.0110.01116.58
7.2.70.0160.00416.22
7.2.60.0120.00916.66
7.2.50.0070.01516.62
7.2.40.0180.00716.40
7.2.30.0140.01416.77
7.2.20.0070.01016.70
7.2.10.0170.01416.61
7.2.00.0110.01018.28
7.1.250.0070.01015.50
7.1.200.0060.00615.76
7.1.100.0040.00818.16
7.1.70.0080.00417.19
7.1.60.0110.01834.98
7.1.50.0230.01334.88
7.1.40.0130.01234.40
7.1.30.0160.00934.67
7.1.20.0130.01334.53
7.1.10.0000.01216.77
7.1.00.0080.00816.91
7.0.200.0070.00816.88
7.0.190.0000.01216.82
7.0.180.0030.00916.24
7.0.170.0090.00516.46
7.0.160.0090.00316.24
7.0.150.0000.01416.20
7.0.140.0030.00916.33
7.0.130.0090.00316.65
7.0.120.0070.00416.59
7.0.110.0040.00816.23
7.0.100.0060.00616.25
7.0.90.0000.01116.27
7.0.80.0030.00916.30
7.0.70.0060.00916.23
7.0.60.0000.01115.91
7.0.50.0030.00916.30
7.0.40.0060.00616.29
7.0.30.0090.00316.44
7.0.20.0080.00616.53
7.0.10.0060.00616.37
7.0.00.0030.00916.37

preferences:
54.03 ms | 401 KiB | 5 Q