3v4l.org

run code in 300+ PHP versions simultaneously
<?php function rec($dir, $depth) { $d = dir($dir); if (!$d) return; while ($entry = $d->read()) { if ($entry == '.' || $entry == '..') continue; echo $depth . $entry . "\n"; if (is_dir($dir . '/' . $entry)) { rec($dir . '/' . $entry, $depth . " "); } } } rec('/', '');

Abusive script

This script was stopped while abusing our resources

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.0.120.0090.00715.13
8.0.110.0160.00315.15
8.0.100.0130.00515.23
8.0.90.0060.00815.26
8.0.80.0160.00515.26
8.0.70.0110.00415.23
8.0.60.0080.00615.18
8.0.50.0070.00915.13
8.0.30.0120.00915.98
8.0.20.0100.00916.11
8.0.10.0110.00515.30
8.0.00.0160.00615.77
7.4.250.0090.00814.89
7.4.240.0080.00615.51
7.4.230.0090.01014.87
7.4.220.0150.00714.81
7.4.210.0140.00514.67
7.4.200.0100.00714.70
7.4.190.0100.01013.27
7.4.180.0100.01013.41
7.4.160.0170.00715.02
7.4.150.0130.00715.39
7.4.140.0080.01316.34
7.4.130.0080.01015.45
7.4.120.0120.00915.47
7.4.110.0110.01114.82
7.4.100.0130.01015.02
7.4.90.0160.00614.78
7.4.80.0100.01016.26
7.4.70.0100.00914.83
7.4.60.0140.00614.84
7.4.50.0080.00814.91
7.4.40.0140.00814.85
7.4.30.0120.00714.91
7.4.20.0210.00013.39
7.4.10.0130.01313.36
7.4.00.0100.01014.53
7.3.310.0120.00414.78
7.3.300.0100.00714.95
7.3.290.0080.01114.91
7.3.280.0120.00715.55
7.3.270.0200.00215.40
7.3.260.0120.01114.89
7.3.250.0080.01215.31
7.3.240.0100.01114.82
7.3.230.0150.00614.99
7.3.220.0180.00313.43
7.3.210.0150.00514.88
7.3.200.0220.00016.41
7.3.190.0120.00814.73
7.3.180.0150.00614.82
7.3.170.0140.00714.79
7.3.160.0080.01014.86
7.3.150.0180.00413.45
7.3.140.0170.00313.37
7.3.130.0100.01013.23
7.3.120.0120.01014.15
7.3.110.0160.00214.11
7.3.100.0150.00313.89
7.3.90.0130.00614.23
7.3.80.0140.00413.90
7.3.70.0110.00813.88
7.3.60.0110.00514.13
7.3.50.0110.00714.14
7.3.40.0070.01114.19
7.3.30.0040.01114.06
7.3.20.0120.00716.05
7.3.10.0100.00415.87
7.3.00.0130.00715.87
7.2.340.0240.00313.50
7.2.330.0160.01015.07
7.2.320.0120.01014.96
7.2.310.0130.01614.91
7.2.300.0200.00315.04
7.2.290.0210.00415.01
7.2.280.0280.00313.39
7.2.270.0200.00613.25
7.2.260.0240.00413.44
7.2.250.0120.01014.28
7.2.240.0150.00714.27
7.2.230.0140.00714.15
7.2.220.0130.01114.16
7.2.210.0140.01114.13
7.2.200.0150.00614.31
7.2.190.0150.00414.24
7.2.180.0160.00514.18
7.2.170.0100.01014.17
7.2.160.0200.00713.40
7.2.150.0150.01115.46
7.2.140.0260.00015.30
7.2.130.0250.00315.42
7.2.120.0190.00615.36
7.2.110.0220.00615.32
7.2.100.0320.00015.39
7.2.90.0260.00715.48
7.2.80.0200.00615.34
7.2.70.0190.00615.48
7.2.60.0250.00415.38
7.2.50.0230.00415.46
7.2.40.0210.01215.29
7.2.30.0210.00715.48
7.2.20.0310.00315.40
7.2.10.0260.00015.47
7.2.00.0150.01015.49
7.1.330.0140.00915.15
7.1.320.0120.00615.12
7.1.310.0170.00515.08
7.1.300.0160.00714.80
7.1.290.0140.01015.12
7.1.280.0140.00915.05
7.1.270.0090.01015.07
7.1.260.0130.01015.15
7.1.250.0230.00714.09
7.1.240.0290.00414.29
7.1.230.0200.00614.34
7.1.220.0250.00614.38
7.1.210.0260.00714.39
7.1.200.0240.00714.40
7.1.190.0250.00914.19
7.1.180.0130.02114.17
7.1.170.0200.01514.31
7.1.160.0190.01014.31
7.1.150.0200.01214.27
7.1.140.0260.00714.23
7.1.130.0250.00814.28
7.1.120.0160.01014.16
7.1.110.0200.01514.34
7.1.100.0180.01514.33
7.1.90.0300.00314.30
7.1.80.0210.00914.16
7.1.70.0100.01015.72
7.1.60.0120.00916.96
7.1.50.0160.01115.59
7.1.40.0250.00714.40
7.1.30.0240.00314.39
7.1.20.0230.00514.32
7.1.10.0220.00414.39
7.1.00.0140.04618.30
7.0.330.0290.00514.22
7.0.320.0190.00614.17
7.0.310.0250.00613.94
7.0.300.0260.00613.99
7.0.290.0200.00614.02
7.0.280.0180.01514.14
7.0.270.0220.00414.07
7.0.260.0260.00014.29
7.0.250.0200.00614.24
7.0.240.0230.01014.38
7.0.200.0030.00616.58
7.0.140.0000.07722.08
7.0.110.0030.08019.95
7.0.100.0170.07719.92
7.0.90.0000.09019.92
7.0.80.0000.09020.08
7.0.70.0070.08319.88
7.0.60.0070.07720.05
7.0.50.0070.08019.98
7.0.40.0130.05719.59
7.0.30.0070.05719.87
7.0.20.0100.07319.77
7.0.10.0030.08019.74
7.0.00.0030.08319.86
5.6.280.0100.06320.91
5.6.260.0070.08320.70
5.6.250.0130.08320.68
5.6.240.0100.07720.68
5.6.230.0130.07720.69
5.6.220.0170.06720.54
5.6.210.0030.04720.56
5.6.200.0070.05020.63
5.6.190.0070.08320.63
5.6.180.0030.05020.59
5.6.170.0000.08320.70
5.6.160.0070.08320.63
5.6.150.0130.07020.61
5.6.140.0130.07020.70
5.6.130.0170.07320.61
5.6.120.0100.06720.57
5.6.110.0130.08020.85
5.6.100.0070.08020.55
5.6.90.0030.07720.84
5.6.80.0030.08020.04
5.6.70.0070.07720.03
5.6.60.0030.08719.93
5.6.50.0130.07020.03
5.6.40.0070.06020.01
5.6.30.0200.03719.95
5.6.20.0100.07719.92
5.6.10.0070.07020.06
5.6.00.0230.06719.91
5.5.380.0070.08317.72
5.5.370.0130.04017.68
5.5.360.0030.08017.68
5.5.350.0070.07017.61
5.5.340.0000.08318.09
5.5.330.0030.08317.91
5.5.320.0130.07317.83
5.5.310.0130.07718.25
5.5.300.0130.04318.23
5.5.290.0170.07317.93
5.5.280.0070.07318.22
5.5.270.0100.07317.95
5.5.260.0130.07318.21
5.5.250.0070.07017.90
5.5.240.0030.07317.48
5.5.230.0030.07717.63
5.5.220.0030.06017.31
5.5.210.0000.05317.51
5.5.200.0030.05017.43
5.5.190.0070.07317.43
5.5.180.0230.04017.28
5.5.160.0070.06717.28
5.5.150.0070.06317.28
5.5.140.0030.08317.26
5.5.130.0100.06017.47
5.5.120.0030.04717.30
5.5.110.0070.07317.60
5.5.100.0030.05317.38
5.5.90.0070.05317.16
5.5.80.0070.03717.18
5.5.70.0000.04017.49
5.5.60.0070.06317.38
5.5.50.0070.03717.17
5.5.40.0030.04017.19
5.5.30.0070.03317.14
5.5.20.0030.03717.07
5.5.10.0170.06317.16
5.5.00.0030.07317.30
5.4.450.0000.08719.50
5.4.440.0000.08319.66
5.4.430.0200.06319.33
5.4.420.0070.08019.33
5.4.410.0070.07719.36
5.4.400.0070.08019.04
5.4.390.0070.08319.14
5.4.380.0100.07319.00
5.4.370.0130.07019.01
5.4.360.0100.07019.17
5.4.350.0030.07719.18
5.4.340.0100.07019.34
5.4.320.0030.08019.03
5.4.310.0070.06019.18
5.4.300.0130.07018.95
5.4.290.0170.06719.14
5.4.280.0070.04019.16
5.4.270.0070.04318.98
5.4.260.0030.04719.13
5.4.250.0030.06719.00
5.4.240.0000.05319.00
5.4.230.0030.03719.01
5.4.220.0000.04019.30
5.4.210.0070.04718.94
5.4.200.0030.03719.23
5.4.190.0130.03719.08
5.4.180.0070.03718.99
5.4.170.0000.04019.00
5.4.160.0030.04019.22
5.4.150.0070.05319.15
5.4.140.0000.04016.42
5.4.130.0130.05016.32
5.4.120.0000.04716.52
5.4.110.0030.07016.42
5.4.100.0030.03716.55
5.4.90.0030.07716.47
5.4.80.0070.03016.39
5.4.70.0000.03716.58
5.4.60.0030.03316.57
5.4.50.0030.03716.41
5.4.40.0070.04016.68
5.4.30.0030.04716.53
5.4.20.0030.03316.38
5.4.10.0030.04316.33
5.4.00.0000.03715.75
5.3.290.0070.07314.75
5.3.280.0000.05014.73
5.3.270.0070.03314.71
5.3.260.0030.06714.75
5.3.250.0130.06314.69
5.3.240.0030.06014.59
5.3.230.0000.04014.59
5.3.220.0070.05014.70
5.3.210.0070.03014.60
5.3.200.0030.04314.62
5.3.190.0030.05314.55
5.3.180.0030.04314.56
5.3.170.0030.04014.64
5.3.160.0100.06714.69
5.3.150.0030.04014.57
5.3.140.0030.04314.63
5.3.130.0030.04314.55
5.3.120.0030.03714.57
5.3.110.0070.03714.54
5.3.100.0000.03714.13
5.3.90.0070.03314.02
5.3.80.0000.04014.01
5.3.70.0000.05013.99
5.3.60.0100.05314.02
5.3.50.0030.03313.93
5.3.40.0100.03714.03
5.3.30.0070.03013.90
5.3.20.0000.03713.83
5.3.10.0070.05013.66
5.3.00.0070.03013.72
5.2.170.0100.02011.13
5.2.160.0000.03011.27
5.2.150.0070.04311.15
5.2.140.0070.02711.13
5.2.130.0030.02711.32
5.2.120.0000.02711.05
5.2.110.0030.03011.24
5.2.100.0000.03011.23
5.2.90.0030.02711.25
5.2.80.0000.05011.10
5.2.70.0000.03011.17
5.2.60.0000.03710.90
5.2.50.0100.02711.03
5.2.40.0100.01711.00
5.2.30.0000.05010.95
5.2.20.0000.03011.08
5.2.10.0070.05310.88
5.2.00.0000.06710.73
5.1.60.0100.0279.98
5.1.50.0100.0479.99
5.1.40.0030.0579.97
5.1.30.0070.05310.35
5.1.20.0070.05710.43
5.1.10.0070.05310.14
5.1.00.0030.05310.31
5.0.50.0000.0479.88
5.0.40.0070.0339.88
5.0.30.0070.0579.88
5.0.20.0030.0479.88
5.0.10.0000.0439.88
5.0.00.0000.0679.88
4.4.90.0030.0239.88
4.4.80.0000.0239.88
4.4.70.0030.0339.88
4.4.60.0030.0279.88
4.4.50.0000.0279.88
4.4.40.0000.0579.88
4.4.30.0070.0279.88
4.4.20.0030.0239.88
4.4.10.0100.0239.88
4.4.00.0030.0509.88
4.3.110.0030.0209.88
4.3.100.0100.0309.88
4.3.90.0030.0309.88
4.3.80.0070.0539.88
4.3.70.0000.0339.88
4.3.60.0030.0309.88
4.3.50.0070.0309.88
4.3.40.0030.0509.88
4.3.30.0000.0379.88
4.3.20.0000.0309.88
4.3.10.0000.0309.88
4.3.00.0000.0309.88

preferences:
39.36 ms | 401 KiB | 5 Q