3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Everything you enter here will be executed by our servers. Try it! $array = array(1, 2, 3, '{1}', '{2}', '{3}', '[1]', '[2]', '[3]'); $filtered_array = array_filter( $array, function( $el) { return preg_match( '/^\[\d+\]$/', $el); }); foreach( $filtered_array as $number) echo $number . "\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.40.0040.01118.85
8.3.30.0070.01519.05
8.3.20.0070.00020.22
8.3.10.0040.00423.52
8.3.00.0110.00420.96
8.2.170.0140.00022.96
8.2.160.0100.01020.45
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0100.01026.16
8.2.120.0070.00022.28
8.2.110.0050.00522.29
8.2.100.0000.01217.91
8.2.90.0080.00019.34
8.2.80.0000.00817.97
8.2.70.0060.00317.75
8.2.60.0080.00317.80
8.2.50.0080.00018.07
8.2.40.0000.00718.22
8.2.30.0040.00418.16
8.2.20.0070.00017.89
8.2.10.0050.00217.77
8.2.00.0050.00317.88
8.1.270.0040.00422.05
8.1.260.0080.00026.35
8.1.250.0060.00328.09
8.1.240.0000.00923.87
8.1.230.0040.00819.10
8.1.220.0030.00517.79
8.1.210.0030.00618.77
8.1.200.0070.00317.48
8.1.190.0000.00817.30
8.1.180.0000.00818.10
8.1.170.0080.00018.59
8.1.160.0000.00722.04
8.1.150.0020.00518.66
8.1.140.0030.00617.56
8.1.130.0030.00317.91
8.1.120.0040.00417.66
8.1.110.0040.00417.50
8.1.100.0000.00717.54
8.1.90.0070.00017.58
8.1.80.0000.00717.58
8.1.70.0070.00017.54
8.1.60.0030.00617.75
8.1.50.0040.00417.73
8.1.40.0030.00617.68
8.1.30.0040.00417.84
8.1.20.0080.00017.80
8.1.10.0000.00817.64
8.1.00.0060.00617.55
8.0.300.0040.00418.77
8.0.290.0000.00717.05
8.0.280.0000.00718.48
8.0.270.0070.00017.34
8.0.260.0000.00816.92
8.0.250.0000.00717.02
8.0.240.0040.00417.01
8.0.230.0000.00717.06
8.0.220.0000.00816.93
8.0.210.0050.00316.98
8.0.200.0070.00017.05
8.0.190.0040.00417.07
8.0.180.0000.00717.01
8.0.170.0040.00416.97
8.0.160.0050.00217.04
8.0.150.0000.00716.94
8.0.140.0000.00717.00
8.0.130.0000.00513.44
8.0.120.0040.00416.99
8.0.110.0070.00017.03
8.0.100.0040.00416.97
8.0.90.0000.00817.10
8.0.80.0060.00916.99
8.0.70.0040.00416.88
8.0.60.0040.00417.05
8.0.50.0080.00016.92
8.0.30.0110.01317.24
8.0.20.0080.01117.40
8.0.10.0070.00017.07
8.0.00.0070.01116.91
7.4.330.0000.00615.10
7.4.320.0030.00316.75
7.4.300.0060.00016.61
7.4.290.0060.00016.66
7.4.280.0030.00316.84
7.4.270.0000.00716.74
7.4.260.0040.00416.75
7.4.250.0070.00016.68
7.4.240.0030.00316.74
7.4.230.0050.00316.84
7.4.220.0210.00316.66
7.4.210.0060.00816.77
7.4.200.0070.00016.55
7.4.190.0030.00316.68
7.4.160.0030.01316.61
7.4.150.0140.00517.40
7.4.140.0070.01017.86
7.4.130.0090.00816.65
7.4.120.0100.00716.75
7.4.110.0130.00316.59
7.4.100.0070.01016.59
7.4.90.0130.00316.87
7.4.80.0100.01419.39
7.4.70.0070.01016.73
7.4.60.0090.01016.63
7.4.50.0060.00316.77
7.4.40.0110.00722.77
7.4.30.0060.00916.65
7.4.10.0060.01315.30
7.4.00.0050.01215.04
7.3.330.0030.00313.25
7.3.320.0030.00313.38
7.3.310.0030.00316.42
7.3.300.0040.00416.49
7.3.290.0060.01316.44
7.3.280.0130.00616.47
7.3.270.0100.00717.40
7.3.260.0060.01616.63
7.3.250.0150.00516.70
7.3.240.0120.00916.57
7.3.230.0070.01016.84
7.3.210.0000.01716.79
7.3.200.0080.01419.39
7.3.190.0160.00616.84
7.3.180.0090.00716.75
7.3.170.0100.00716.34
7.3.160.0080.00816.38
7.3.130.0060.01014.82
7.3.120.0110.00114.95
7.3.110.0110.00414.88
7.3.100.0130.00014.85
7.3.90.0040.01514.69
7.3.80.0000.01614.86
7.3.70.0000.01014.85
7.3.60.0070.01015.12
7.3.50.0000.01414.95
7.3.40.0070.00315.00
7.3.30.0110.00315.06
7.3.20.0080.00417.02
7.3.10.0040.01216.79
7.3.00.0090.00616.71
7.2.330.0110.00816.70
7.2.320.0080.00916.61
7.2.310.0090.00916.93
7.2.300.0000.02016.70
7.2.290.0030.01516.90
7.2.260.0100.01015.31
7.2.250.0030.01315.10
7.2.240.0090.00615.19
7.2.230.0070.01315.40
7.2.220.0040.01115.01
7.2.210.0100.00314.94
7.2.200.0060.00314.97
7.2.190.0070.01315.21
7.2.180.0090.00915.35
7.2.170.0030.01015.14
7.2.160.0060.00315.25
7.2.150.0080.00816.98
7.2.140.0040.00717.19
7.2.130.0060.00617.28
7.2.120.0000.01117.02
7.2.110.0030.00617.13
7.2.100.0110.00317.05
7.2.90.0040.00816.83
7.2.80.0000.01217.14
7.2.70.0060.00917.12
7.2.60.0050.00917.11
7.2.50.0060.00317.24
7.2.40.0030.00916.95
7.2.30.0090.00617.11
7.2.20.0030.01417.23
7.2.10.0100.00717.21
7.2.00.0070.00417.20
7.1.330.0040.01116.13
7.1.320.0060.00815.82
7.1.310.0090.00315.89
7.1.300.0070.01115.88
7.1.290.0100.00016.15
7.1.280.0070.00715.84
7.1.270.0070.00715.89
7.1.260.0040.01115.88
7.1.250.0030.01016.07
7.1.240.0120.00015.72
7.1.230.0030.00715.97
7.1.220.0060.00615.65
7.1.210.0000.01415.91
7.1.200.0060.00615.81
7.1.190.0030.01315.71
7.1.180.0070.01016.03
7.1.170.0060.00816.07
7.1.160.0080.00316.15
7.1.150.0030.00715.90
7.1.140.0110.00715.85
7.1.130.0090.00615.86
7.1.120.0090.00316.08
7.1.110.0110.00615.83
7.1.100.0090.00417.27
7.1.90.0100.00615.93
7.1.80.0060.00615.90
7.1.70.0040.00416.78
7.1.60.0100.00917.62
7.1.50.0070.01216.42
7.1.40.0080.00416.05
7.1.30.0060.00315.85
7.1.20.0030.00915.80
7.1.10.0100.01015.98
7.1.00.0090.03919.25
7.0.330.0040.01115.62
7.0.320.0050.00515.62
7.0.310.0000.01015.40
7.0.300.0040.00415.63
7.0.290.0030.01015.66
7.0.280.0040.00815.55
7.0.270.0060.00315.66
7.0.260.0030.00915.35
7.0.250.0070.00415.71
7.0.240.0040.00715.48
7.0.230.0070.01015.29
7.0.220.0030.00715.68
7.0.210.0120.00015.77
7.0.200.0050.00916.04
7.0.190.0070.00715.52
7.0.180.0040.00715.71
7.0.170.0000.01015.70
7.0.160.0000.01315.66
7.0.150.0070.00315.28
7.0.140.0020.04118.79
7.0.130.0060.00615.61
7.0.120.0100.00315.63
7.0.110.0040.00815.61
7.0.100.0050.03117.83
7.0.90.0020.02917.58
7.0.80.0010.02917.74
7.0.70.0060.04017.72
7.0.60.0090.02017.57
7.0.50.0030.02017.98
7.0.40.0030.02516.78
7.0.30.0080.02316.92
7.0.20.0030.02516.91
7.0.10.0030.02616.86
7.0.00.0050.02016.75
5.6.400.0030.01014.64
5.6.390.0060.00313.96
5.6.380.0030.00914.19
5.6.370.0060.01014.47
5.6.360.0030.00614.38
5.6.350.0060.00914.32
5.6.340.0060.00914.29
5.6.330.0040.00714.63
5.6.320.0030.00614.24
5.6.310.0060.00614.67
5.6.300.0000.01614.37
5.6.290.0070.00414.40
5.6.280.0030.04017.72
5.6.270.0070.00314.71
5.6.260.0040.00814.18
5.6.250.0070.02517.60
5.6.240.0020.02517.55
5.6.230.0060.02317.57
5.6.220.0050.02117.52
5.6.210.0110.02117.43
5.6.200.0040.02317.62
5.6.190.0070.02317.69
5.6.180.0040.02417.63
5.6.170.0020.02917.84
5.6.160.0020.02717.70
5.6.150.0060.02317.74
5.6.140.0030.02717.77
5.6.130.0050.02317.69
5.6.120.0080.03517.76
5.6.110.0050.02617.67
5.6.100.0060.02117.65
5.6.90.0060.02517.58
5.6.80.0030.03817.50
5.6.70.0080.02217.23
5.6.60.0100.04017.27
5.6.50.0120.03517.44
5.6.40.0030.03517.31
5.6.30.0120.03717.41
5.6.20.0000.04917.29
5.6.10.0100.03817.21
5.6.00.0080.03617.37
5.5.380.0030.02817.30
5.5.370.0090.01817.37
5.5.360.0030.02317.38
5.5.350.0080.02017.29
5.5.340.0040.02017.76
5.5.330.0120.02317.67
5.5.320.0080.02217.46
5.5.310.0080.02517.42
5.5.300.0030.02517.45
5.5.290.0050.02517.78
5.5.280.0040.02617.41
5.5.270.0060.02317.52
5.5.260.0020.02817.69
5.5.250.0020.03117.46
5.5.240.0070.02817.29
5.5.230.0040.04317.34
5.5.220.0050.04317.21
5.5.210.0030.03017.20
5.5.200.0020.04417.18
5.5.190.0070.02017.14
5.5.180.0060.03817.08
5.5.170.0060.00314.04
5.5.160.0070.04117.20
5.5.150.0100.03717.19
5.5.140.0080.03517.22
5.5.130.0070.02017.05
5.5.120.0090.04117.13
5.5.110.0050.03817.10
5.5.100.0050.03617.29
5.5.90.0060.04017.23
5.5.80.0150.03217.17
5.5.70.0070.02717.22
5.5.60.0070.02417.27
5.5.50.0070.03317.07
5.5.40.0050.03417.08
5.5.30.0050.04317.23
5.5.20.0130.03717.04
5.5.10.0090.03917.30
5.5.00.0120.01817.14
5.4.450.0040.02115.77
5.4.440.0050.02315.73
5.4.430.0070.02215.69
5.4.420.0020.02615.80
5.4.410.0030.04315.77
5.4.400.0080.02015.53
5.4.390.0020.04015.61
5.4.380.0000.02515.69
5.4.370.0080.03515.61
5.4.360.0020.02415.69
5.4.350.0080.04015.62
5.4.340.0110.03515.68
5.4.330.0060.00912.19
5.4.320.0080.04015.62
5.4.310.0020.04515.57
5.4.300.0080.04015.68
5.4.290.0060.04215.65
5.4.280.0060.04515.64
5.4.270.0040.04415.65
5.4.260.0060.01815.54
5.4.250.0060.04115.68
5.4.240.0030.03915.60
5.4.230.0090.03515.65
5.4.220.0060.03515.66
5.4.210.0020.02615.56
5.4.200.0050.03715.61
5.4.190.0020.02115.62
5.4.180.0060.03615.70
5.4.170.0050.03415.70
5.4.160.0050.02315.70
5.4.150.0020.02315.68
5.4.140.0020.02414.31
5.4.130.0020.02814.35
5.4.120.0080.02014.32
5.4.110.0080.03914.29
5.4.100.0050.04414.24
5.4.90.0070.03514.34
5.4.80.0020.02714.23
5.4.70.0040.02814.34
5.4.60.0080.02814.24
5.4.50.0050.02314.28
5.4.40.0050.03914.32
5.4.30.0050.02614.25
5.4.20.0050.02514.29
5.4.10.0070.03714.33
5.4.00.0000.02713.91
5.3.290.0060.03813.44
5.3.280.0050.04213.37
5.3.270.0050.02413.45
5.3.260.0110.03313.42
5.3.250.0030.04213.36
5.3.240.0030.02613.36
5.3.230.0010.04213.39
5.3.220.0060.04013.37
5.3.210.0040.03313.39
5.3.200.0100.02213.40
5.3.190.0060.03313.42
5.3.180.0050.03913.33
5.3.170.0020.02813.38
5.3.160.0050.02813.38
5.3.150.0030.03313.44
5.3.140.0030.02813.40
5.3.130.0050.02713.39
5.3.120.0080.03713.40
5.3.110.0140.03813.40
5.3.100.0030.03813.07
5.3.90.0020.04213.10
5.3.80.0030.04413.17
5.3.70.0030.04513.09
5.3.60.0080.03713.13
5.3.50.0050.04013.13
5.3.40.0020.04413.06
5.3.30.0050.03213.07
5.3.20.0060.02512.93
5.3.10.0020.03912.88
5.3.00.0090.03312.92
5.2.170.0070.04311.54
5.2.160.0030.04711.54
5.2.150.0130.05711.54
5.2.140.0030.04311.54
5.2.130.0030.05011.54
5.2.120.0070.06011.54
5.2.110.0000.06311.54
5.2.100.0130.03711.54
5.2.90.0070.04311.54
5.2.80.0000.05711.54
5.2.70.0070.05011.54
5.2.60.0100.05311.54
5.2.50.0030.06011.54
5.2.40.0030.04711.54
5.2.30.0070.06311.54
5.2.20.0070.05711.54
5.2.10.0130.04011.54
5.2.00.0030.06311.54
5.1.60.0030.05011.54
5.1.50.0030.06011.54
5.1.40.0030.05011.54
5.1.30.0070.05711.54
5.1.20.0130.03311.54
5.1.10.0070.05311.54
5.1.00.0100.03711.54
5.0.50.0000.04311.54
5.0.40.0000.04711.54
5.0.30.0030.06711.54
5.0.20.0030.04311.54
5.0.10.0030.04011.54
5.0.00.0030.06011.54
4.4.90.0000.02011.54
4.4.80.0000.03311.54
4.4.70.0070.02711.54
4.4.60.0000.03711.54
4.4.50.0000.03011.54
4.4.40.0070.02311.54
4.4.30.0030.03311.54
4.4.20.0000.04011.54
4.4.10.0100.02711.54
4.4.00.0000.04311.54
4.3.110.0000.03711.54
4.3.100.0030.02711.54
4.3.90.0000.03311.54
4.3.80.0030.05011.54
4.3.70.0030.03311.54
4.3.60.0030.02711.54
4.3.50.0030.03311.54
4.3.40.0030.05011.54
4.3.30.0000.03711.54
4.3.20.0030.02711.54
4.3.10.0000.03711.54
4.3.00.0000.03311.54

preferences:
52.54 ms | 400 KiB | 5 Q