3v4l.org

run code in 300+ PHP versions simultaneously
<?php $offset = "-1100"; $hours = substr($offset, 0, strlen(offset) - 2); $minutes = substr($offset, -2); $seconds = $hours * 60 * 60 + $minutes * 60; $tz = timezone_name_from_abbr('', $seconds, 1); $log->d("Timezone from offset: [".var_export($tz,true)."]"); if($tz === false) $tz = timezone_name_from_abbr('', $seconds, 0); $data["localtime"] = \DateTime::createFromFormat( 'Y-m-d H:i:s', $data[0]['weatherReportTime'], new \DateTimeZone($tz)); $log->d("LOCAL TIME: [".var_export($data["localtime"],true)."]");

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.0000.01416.63
8.3.50.0110.00416.46
8.3.40.0060.00918.92
8.3.30.0150.00718.72
8.3.20.0030.00620.30
8.3.10.0030.00521.75
8.3.00.0040.00423.48
8.2.180.0030.01717.00
8.2.170.0030.01122.96
8.2.160.0070.01420.26
8.2.150.0040.00424.18
8.2.140.0070.00024.66
8.2.130.0080.00021.00
8.2.120.0040.00426.35
8.2.110.0030.00719.13
8.2.100.0060.00617.93
8.2.90.0040.00419.20
8.2.80.0050.00317.97
8.2.70.0000.00917.63
8.2.60.0040.00417.92
8.2.50.0080.00018.09
8.2.40.0040.00420.55
8.2.30.0040.00419.44
8.2.20.0070.00017.64
8.2.10.0070.00018.13
8.2.00.0020.00518.11
8.1.280.0140.00725.92
8.1.270.0000.00822.19
8.1.260.0000.00728.09
8.1.250.0040.00428.09
8.1.240.0060.00322.17
8.1.230.0040.00817.82
8.1.220.0050.00317.74
8.1.210.0000.00818.77
8.1.200.0000.00917.48
8.1.190.0080.00017.35
8.1.180.0080.00018.10
8.1.170.0080.00018.65
8.1.160.0040.00420.78
8.1.150.0070.00020.72
8.1.140.0040.00419.52
8.1.130.0030.00317.63
8.1.120.0040.00417.39
8.1.110.0000.00717.39
8.1.100.0040.00417.45
8.1.90.0000.00717.38
8.1.80.0040.00417.43
8.1.70.0030.00317.46
8.1.60.0040.00417.63
8.1.50.0030.00617.43
8.1.40.0030.00617.43
8.1.30.0040.00417.52
8.1.20.0070.00017.61
8.1.10.0000.00817.45
8.1.00.0000.00717.51
8.0.300.0050.00318.77
8.0.290.0030.00616.63
8.0.280.0000.00718.37
8.0.270.0070.00017.19
8.0.260.0040.00417.18
8.0.250.0030.00316.90
8.0.240.0000.00817.05
8.0.230.0000.00717.02
8.0.220.0000.00717.01
8.0.210.0000.00716.92
8.0.200.0000.00617.09
8.0.190.0000.00816.96
8.0.180.0000.00717.00
8.0.170.0040.00416.89
8.0.160.0000.00716.95
8.0.150.0030.00316.91
8.0.140.0050.00316.88
8.0.130.0050.00013.36
8.0.120.0060.00316.84
8.0.110.0040.00416.87
8.0.100.0060.00316.95
8.0.90.0070.00016.97
8.0.80.0130.00717.03
8.0.70.0030.00516.77
8.0.60.0040.00416.83
8.0.50.0030.00516.77
8.0.30.0110.00917.11
8.0.20.0140.00917.40
8.0.10.0050.00217.02
8.0.00.0130.00816.86
7.4.330.0060.00016.71
7.4.320.0000.00616.52
7.4.300.0000.00716.59
7.4.290.0040.00416.61
7.4.280.0050.00316.51
7.4.270.0060.00016.43
7.4.260.0030.00316.50
7.4.250.0000.00816.40
7.4.240.0000.00716.61
7.4.230.0040.00416.52
7.4.220.0080.01216.46
7.4.210.0110.00616.69
7.4.200.0000.00816.36
7.4.160.0080.00816.61
7.4.150.0070.01117.40
7.4.140.0070.01417.86
7.4.130.0110.00616.63
7.4.120.0100.00816.62
7.4.110.0090.00916.47
7.4.100.0070.01716.62
7.4.90.0080.00816.60
7.4.80.0070.01019.39
7.4.70.0050.01116.58
7.4.60.0100.00716.43
7.4.50.0090.00616.47
7.4.40.0090.01516.53
7.4.30.0100.00716.66
7.4.00.0070.00715.27
7.3.330.0000.00613.20
7.3.320.0000.00513.19
7.3.310.0070.00016.49
7.3.300.0050.00216.20
7.3.290.0080.01016.33
7.3.280.0080.01016.36
7.3.270.0150.00317.40
7.3.260.0160.00016.44
7.3.250.0120.00916.52
7.3.240.0090.00916.49
7.3.230.0060.01116.61
7.3.210.0060.00916.47
7.3.200.0120.00819.39
7.3.190.0100.00716.34
7.3.180.0110.01216.41
7.3.170.0130.01016.69
7.3.160.0140.00316.30
7.3.120.0070.00716.90
7.3.110.0060.00616.90
7.3.100.0070.00716.90
7.3.90.0080.00816.90
7.3.80.0110.00316.90
7.3.70.0110.00416.90
7.3.60.0040.00816.90
7.3.50.0000.01216.90
7.3.40.0000.01216.90
7.3.30.0040.01116.90
7.3.20.0120.00616.90
7.3.10.0030.01016.90
7.3.00.0000.00916.90
7.2.330.0100.00716.88
7.2.320.0000.01716.82
7.2.310.0070.00816.88
7.2.300.0060.01116.79
7.2.290.0110.00616.76
7.2.240.0090.00616.90
7.2.230.0000.01616.90
7.2.220.0030.01316.90
7.2.210.0070.01116.90
7.2.200.0060.00916.90
7.2.190.0000.01616.90
7.2.180.0090.00916.90
7.2.170.0040.01216.90
7.2.160.0040.01516.90
7.2.150.0070.00716.90
7.2.140.0060.00616.96
7.2.130.0060.00916.93
7.2.120.0070.01116.90
7.2.110.0060.00616.92
7.2.100.0040.01216.90
7.2.90.0100.00716.90
7.2.80.0050.00616.97
7.2.70.0060.00917.06
7.2.60.0060.00817.01
7.2.50.0000.01217.11
7.2.40.0070.01017.01
7.2.30.0080.00817.05
7.2.20.0040.01516.90
7.2.10.0070.00717.12
7.2.00.0040.01018.14
7.1.330.0030.01016.90
7.1.320.0080.00616.90
7.1.310.0080.00816.90
7.1.300.0100.00616.90
7.1.290.0040.01116.90
7.1.280.0070.00416.90
7.1.270.0030.01216.90
7.1.260.0080.00816.90
7.1.250.0030.01216.90
7.1.200.0060.00915.48
7.1.100.0060.00618.14
7.1.70.0070.00717.29
7.1.60.0090.01619.40
7.1.50.0030.01717.03
7.1.00.0030.07722.45
7.0.200.0640.00714.66
7.0.60.0230.07321.78
7.0.50.0130.07717.87
7.0.40.0030.09020.20
7.0.30.0230.07720.16
7.0.20.0230.04320.30
7.0.10.0070.08320.16
7.0.00.0030.04020.00
5.6.280.0000.03321.09
5.6.210.0100.05720.76
5.6.200.0070.08018.13
5.6.190.0070.07020.39
5.6.180.0270.08720.69
5.6.170.0430.07020.50
5.6.160.0100.04720.75
5.6.150.0070.07718.11
5.6.140.0030.04018.18
5.6.130.0000.06018.16
5.6.120.0030.04321.00
5.6.110.0170.04721.09
5.6.100.0070.07721.03
5.6.90.0200.04321.01
5.6.80.0100.07020.50
5.5.350.0230.08320.44
5.5.340.0070.04018.01
5.5.330.0030.04720.41
5.5.320.0230.04020.28
5.5.310.0230.04720.23
5.5.300.0000.07018.02
5.5.290.0170.06018.05
5.5.280.0000.05320.77
5.5.270.0070.07320.89
5.5.260.0070.07020.79
5.5.250.0000.04720.58
5.5.240.0300.06720.16

preferences:
63.55 ms | 400 KiB | 5 Q