3v4l.org

run code in 300+ PHP versions simultaneously
<?php $year = '2015'; $week = '01'; $month = date('m', strtotime($year . 'W' . $week)); $weeks = [ '0' => ((int)$week == 1) ? date('W', strtotime('December 28th,' . $year - 1)) : (int)$week - 1, '1' => $week, '2' => (date('W', strtotime('December 28th,' . $year)) == $week) ? '01' : (int)$week + 1, '3' => (date('W', strtotime('December 28th,' . $year)) == $week) ? '01' : (int)$week + 2, '4' => (date('W', strtotime('December 28th,' . $year)) == $week) ? '01' : (int)$week + 3, '5' => (date('W', strtotime('December 28th,' . $year)) == $week) ? '01' : (int)$week + 4 ]; print_r(date('W', strtotime('December 28th,' . $year)));

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.70.0110.00416.63
8.3.60.0040.01516.75
8.3.50.0140.01221.22
8.3.40.0110.00718.89
8.3.30.0040.01118.96
8.3.20.0030.01020.33
8.3.10.0040.00423.66
8.3.00.0040.00419.69
8.2.190.0140.00416.84
8.2.180.0160.00616.75
8.2.170.0090.00622.96
8.2.160.0070.01020.53
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0000.00826.16
8.2.120.0000.00817.75
8.2.110.0030.00719.39
8.2.100.0080.00417.75
8.2.90.0100.00019.30
8.2.80.0060.00317.97
8.2.70.0100.00317.73
8.2.60.0050.00317.80
8.2.50.0000.00818.07
8.2.40.0030.00619.46
8.2.30.0030.00718.20
8.2.20.0000.00818.05
8.2.10.0060.00318.20
8.2.00.0040.00418.26
8.1.280.0070.01125.92
8.1.270.0090.00022.21
8.1.260.0040.00426.35
8.1.250.0050.00328.09
8.1.240.0060.00321.24
8.1.230.0040.00717.89
8.1.220.0040.00417.77
8.1.210.0030.00618.77
8.1.200.0030.00617.48
8.1.190.0030.00617.48
8.1.180.0040.00418.10
8.1.170.0060.00318.65
8.1.160.0040.00422.04
8.1.150.0020.00518.97
8.1.140.0030.00517.70
8.1.130.0000.00717.90
8.1.120.0040.00417.59
8.1.110.0000.00717.69
8.1.100.0030.00417.63
8.1.90.0040.00417.55
8.1.80.0000.00717.57
8.1.70.0030.00317.66
8.1.60.0000.00817.69
8.1.50.0080.00017.57
8.1.40.0000.00917.64
8.1.30.0000.00917.78
8.1.20.0000.00817.77
8.1.10.0050.00317.74
8.1.00.0050.00217.69
8.0.300.0040.00418.77
8.0.290.0050.00217.00
8.0.280.0000.00818.42
8.0.270.0030.00317.27
8.0.260.0090.00017.27
8.0.250.0000.00817.20
8.0.240.0000.00717.23
8.0.230.0040.00417.23
8.0.220.0000.00717.15
8.0.210.0040.00417.17
8.0.200.0000.00617.23
8.0.190.0000.00817.20
8.0.180.0050.00217.08
8.0.170.0000.00717.09
8.0.160.0040.00417.14
8.0.150.0040.00417.16
8.0.140.0030.00617.11
8.0.130.0050.00013.54
8.0.120.0000.00817.05
8.0.110.0030.00517.08
8.0.100.0040.00417.21
8.0.90.0000.00817.14
8.0.80.0150.00017.19
8.0.70.0040.00417.13
8.0.60.0040.00416.98
8.0.50.0040.00417.23
8.0.30.0140.00517.33
8.0.20.0100.00917.40
8.0.10.0040.00417.24
8.0.00.0100.00816.92
7.4.330.0050.00015.08
7.4.320.0030.00316.56
7.4.300.0030.00516.76
7.4.290.0000.00716.66
7.4.280.0000.00716.77
7.4.270.0030.00716.79
7.4.260.0040.00816.56
7.4.250.0000.00816.64
7.4.240.0040.00316.74
7.4.230.0040.00416.67
7.4.220.0120.00616.67
7.4.210.0090.00616.61
7.4.200.0000.00716.77
7.4.160.0060.01016.88
7.4.150.0060.01217.40
7.4.140.0140.00617.86
7.4.130.0100.00916.75
7.4.120.0140.00716.73
7.4.110.0100.01016.78
7.4.100.0070.01316.64
7.4.90.0130.00416.78
7.4.80.0110.00719.39
7.4.70.0150.00916.67
7.4.60.0120.00616.89
7.4.50.0020.00216.60
7.4.40.0060.01616.75
7.4.30.0030.01416.72
7.4.10.0080.01215.10
7.4.00.0030.01315.12
7.3.330.0080.00013.33
7.3.320.0000.00613.27
7.3.310.0070.00016.47
7.3.300.0030.00316.39
7.3.290.0090.01016.54
7.3.280.0120.01016.60
7.3.270.0150.00917.40
7.3.260.0200.00316.64
7.3.250.0100.00716.63
7.3.240.0140.00716.78
7.3.230.0160.00716.77
7.3.210.0090.01516.62
7.3.200.0130.00316.46
7.3.190.0070.01016.58
7.3.180.0110.00716.64
7.3.170.0000.01616.73
7.3.160.0130.00316.55
7.3.130.0100.01015.09
7.3.120.0080.00915.13
7.3.110.0100.01015.16
7.3.100.0070.00715.18
7.3.90.0060.00915.11
7.3.80.0060.00815.25
7.3.70.0030.01115.04
7.3.60.0040.00615.05
7.3.50.0070.00614.96
7.3.40.0090.00615.01
7.3.30.0080.00614.84
7.3.20.0070.00916.90
7.3.10.0060.01016.73
7.3.00.0080.00816.73
7.2.330.0030.01416.93
7.2.320.0100.01416.75
7.2.310.0190.00316.91
7.2.300.0150.00716.93
7.2.290.0120.00916.86
7.2.260.0090.00915.21
7.2.250.0070.01215.45
7.2.240.0110.00415.31
7.2.230.0020.01215.13
7.2.220.0040.00815.07
7.2.210.0050.01215.03
7.2.200.0040.01015.05
7.2.190.0000.01115.27
7.2.180.0060.01015.38
7.2.170.0040.01215.37
7.2.160.0040.00615.17
7.2.150.0080.00717.13
7.2.140.0050.01017.11
7.2.130.0080.01016.96
7.2.120.0070.00916.90
7.2.110.0040.01117.07
7.2.100.0070.00716.95
7.2.90.0090.00516.81
7.2.80.0070.00816.94
7.2.70.0100.00817.04
7.2.60.0080.00817.00
7.2.50.0080.00817.00
7.2.40.0140.00516.82
7.2.30.0080.00816.92
7.2.20.0090.00917.07
7.2.10.0060.01317.03
7.2.00.0080.00817.76
7.1.330.0050.00916.00
7.1.320.0030.01015.94
7.1.310.0070.00815.79
7.1.300.0060.00616.00
7.1.290.0070.01016.04
7.1.280.0050.00915.98
7.1.270.0050.00915.96
7.1.260.0000.01015.92
7.1.250.0070.00416.02
7.1.240.0080.00516.02
7.1.230.0030.01015.81
7.1.220.0080.00815.96
7.1.210.0070.00515.95
7.1.200.0110.00215.94
7.1.190.0030.00816.03
7.1.180.0030.00916.03
7.1.170.0050.01016.10
7.1.160.0060.00615.68
7.1.150.0090.00315.92
7.1.140.0070.00716.05
7.1.130.0070.00716.03
7.1.120.0100.00315.82
7.1.110.0090.00615.90
7.1.100.0040.00916.72
7.1.90.0020.00715.92
7.1.80.0080.00515.99
7.1.70.0040.00816.35
7.1.60.0070.00917.08
7.1.50.0080.01016.35
7.1.40.0050.00715.97
7.1.30.0080.00315.82
7.1.20.0080.00215.98
7.1.10.0030.01015.89
7.1.00.0040.03218.12
7.0.330.0020.01215.48
7.0.320.0050.00815.58
7.0.310.0040.01115.71
7.0.300.0050.00915.62
7.0.290.0070.00615.32
7.0.280.0090.00715.68
7.0.270.0010.01115.42
7.0.260.0050.00915.61
7.0.250.0070.00715.71
7.0.240.0010.01215.63
7.0.230.0060.00615.63
7.0.220.0030.01015.71
7.0.210.0100.00215.52
7.0.200.0010.01315.36
7.0.190.0020.01215.58
7.0.180.0080.00315.62
7.0.170.0060.00915.71
7.0.160.0040.00815.59
7.0.150.0040.01215.72
7.0.140.0040.01115.66
7.0.130.0020.01015.51
7.0.120.0020.01015.63
7.0.110.0050.00915.53
7.0.100.0110.02416.94
7.0.90.0090.02917.04
7.0.80.0080.02816.99
7.0.70.0150.02317.07
7.0.60.0070.03216.99
7.0.50.0030.03417.28
7.0.40.0060.02215.85
7.0.30.0070.02715.82
7.0.20.0090.03115.84
7.0.10.0080.02915.74
7.0.00.0050.02715.82
5.6.400.0070.00714.57
5.6.390.0060.00614.70
5.6.380.0050.00814.44
5.6.370.0050.00714.63
5.6.360.0100.00714.54
5.6.350.0020.01114.52
5.6.340.0020.01214.70
5.6.330.0020.01114.57
5.6.320.0040.01014.47
5.6.310.0020.01214.53
5.6.300.0060.00814.51
5.6.290.0100.00314.54
5.6.280.0040.01516.75
5.6.270.0010.01014.57
5.6.260.0040.01114.68
5.6.250.0070.02516.63
5.6.240.0040.03316.56
5.6.230.0090.02816.46
5.6.220.0060.03216.52
5.6.210.0080.02916.52
5.6.200.0050.03616.51
5.6.190.0100.02516.67
5.6.180.0080.03116.60
5.6.170.0050.03316.69
5.6.160.0060.02216.70
5.6.150.0080.02416.62
5.6.140.0100.02716.59
5.6.130.0070.03116.68
5.6.120.0090.02916.55
5.6.110.0050.03416.56
5.6.100.0100.02816.75
5.6.90.0050.03516.56
5.6.80.0020.03516.34
5.6.70.0090.03216.40
5.6.60.0080.02916.39
5.6.50.0060.03216.49
5.6.40.0030.03016.39
5.6.30.0080.01916.35
5.6.20.0140.02716.36
5.6.10.0080.01816.30
5.6.00.0060.02416.35
5.5.380.0080.03016.44
5.5.370.0020.03516.24
5.5.360.0070.01916.39
5.5.350.0060.03216.44
5.5.340.0090.02216.48
5.5.330.0060.02616.56
5.5.320.0050.02416.62
5.5.310.0080.02916.46
5.5.300.0040.03316.53
5.5.290.0040.03516.38
5.5.280.0020.03516.72
5.5.270.0010.02616.58
5.5.260.0100.03216.51
5.5.250.0030.02516.53
5.5.240.0030.02316.36
5.5.230.0100.03316.37
5.5.220.0120.02616.33
5.5.210.0080.01716.36
5.5.200.0080.03316.32
5.5.190.0050.03416.22
5.5.180.0010.02616.22
5.5.170.0060.00614.45
5.5.160.0040.03316.32
5.5.150.0050.03116.19
5.5.140.0090.02716.31
5.5.130.0040.03316.18
5.5.120.0040.02216.28
5.5.110.0100.01716.36
5.5.100.0060.01916.36
5.5.90.0070.02816.24
5.5.80.0050.03316.25
5.5.70.0020.02916.25
5.5.60.0030.03216.33
5.5.50.0040.01716.07
5.5.40.0080.02716.12
5.5.30.0050.01816.31
5.5.20.0020.03516.34
5.5.10.0050.03016.31
5.5.00.0040.03116.30
5.4.450.0040.03114.23
5.4.440.0040.02314.16
5.4.430.0080.02714.10
5.4.420.0080.02614.14
5.4.410.0070.02914.19
5.4.400.0040.03014.02
5.4.390.0100.02314.00
5.4.380.0060.02914.05
5.4.370.0090.02714.11
5.4.360.0080.02513.90
5.4.350.0070.02014.05
5.4.340.0050.02213.99
5.4.330.0040.00611.56
5.4.320.0020.02614.04
5.4.310.0040.01714.01
5.4.300.0050.01714.14
5.4.290.0030.02914.01
5.4.280.0030.02013.96
5.4.270.0050.01813.96
5.4.260.0050.01714.04
5.4.250.0040.02814.06
5.4.240.0040.03114.05
5.4.230.0050.02814.02
5.4.220.0030.02414.13
5.4.210.0050.02614.13
5.4.200.0010.02113.91
5.4.190.0080.01714.05
5.4.180.0080.02714.02
5.4.170.0040.02914.07
5.4.160.0040.03014.01
5.4.150.0030.03014.04
5.4.140.0060.02513.24
5.4.130.0110.02313.19
5.4.120.0030.02313.06
5.4.110.0070.02413.19
5.4.100.0010.02413.10
5.4.90.0070.02113.16
5.4.80.0080.02613.19
5.4.70.0040.02813.19
5.4.60.0080.02113.13
5.4.50.0030.02913.18
5.4.40.0040.03113.12
5.4.30.0030.02113.10
5.4.20.0070.02213.16
5.4.10.0070.02713.00
5.4.00.0070.02612.99

preferences:
73.78 ms | 401 KiB | 5 Q