3v4l.org

run code in 300+ PHP versions simultaneously
<?php function sunTimes($lat, $long, $date) { date_default_timezone_set('UTC'); $sun_info = date_sun_info(strtotime($date), $lat, $long); $sunrise = date("H:i:s", $sun_info['sunrise']); $sunset = date("H:i:s", $sun_info['sunset']); return "on $date sun rises at $sunrise and sets at $sunset"; } echo sunTimes(51.5, 0, '2018-03-14'); // ~London

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.0150.00618.68
8.3.50.0160.00516.82
8.3.40.0110.00719.15
8.3.30.0110.00319.40
8.3.20.0070.00022.25
8.3.10.0000.00720.86
8.3.00.0040.00423.98
8.2.180.0060.01619.17
8.2.170.0060.01222.96
8.2.160.0000.01421.56
8.2.150.0030.00924.18
8.2.140.0040.00424.66
8.2.130.0080.00026.16
8.2.120.0070.00026.16
8.2.110.0080.00322.65
8.2.100.0080.00418.41
8.2.90.0080.00018.34
8.2.80.0030.00518.43
8.2.70.0060.00318.66
8.2.60.0090.00018.72
8.2.50.0000.00818.13
8.2.40.0000.00820.03
8.2.30.0000.00719.72
8.2.20.0000.00718.57
8.2.10.0040.00419.61
8.2.00.0050.00319.95
8.1.280.0130.00725.92
8.1.270.0030.00722.50
8.1.260.0080.00026.35
8.1.250.0080.00028.09
8.1.240.0040.00422.46
8.1.230.0080.00421.32
8.1.220.0080.00018.28
8.1.210.0000.00819.16
8.1.200.0000.00917.73
8.1.190.0030.00617.72
8.1.180.0040.00418.10
8.1.170.0050.00318.90
8.1.160.0000.00719.39
8.1.150.0040.00419.24
8.1.140.0000.00819.25
8.1.130.0030.00320.51
8.1.120.0100.00017.96
8.1.110.0040.00417.89
8.1.100.0080.00018.00
8.1.90.0040.00417.95
8.1.80.0080.00017.78
8.1.70.0050.00217.93
8.1.60.0040.00418.06
8.1.50.0000.00817.94
8.1.40.0000.00918.00
8.1.30.0030.00518.09
8.1.20.0040.00418.09
8.1.10.0040.00418.10
8.1.00.0030.00618.02
8.0.300.0040.00420.50
8.0.290.0080.00017.13
8.0.280.0000.00818.83
8.0.270.0030.00317.78
8.0.260.0070.00024.13
8.0.250.0000.00717.46
8.0.240.0030.00317.51
8.0.230.0060.00317.43
8.0.220.0030.00617.43
8.0.210.0030.00317.45
8.0.200.0020.00517.48
8.0.190.0080.00017.48
8.0.180.0000.00817.48
8.0.170.0040.00417.29
8.0.160.0030.00617.52
8.0.150.0000.00717.37
8.0.140.0040.00417.43
8.0.130.0000.00713.79
8.0.120.0040.00417.43
8.0.110.0000.00817.45
8.0.100.0080.00017.35
8.0.90.0040.00417.38
8.0.80.0100.00617.24
8.0.70.0060.00317.34
8.0.60.0050.00317.42
8.0.50.0040.00417.46
8.0.30.0110.00517.39
8.0.20.0110.00917.44
8.0.10.0040.00417.59
8.0.00.0110.00817.10
7.4.330.0030.00315.55
7.4.320.0000.00616.85
7.4.300.0000.00717.00
7.4.290.0030.00517.09
7.4.280.0050.00317.01
7.4.270.0040.00417.05
7.4.260.0000.00717.03
7.4.250.0040.00416.99
7.4.240.0020.00517.09
7.4.230.0050.00316.97
7.4.220.0000.00716.74
7.4.210.0060.01116.94
7.4.200.0030.00317.11
7.4.130.0100.00716.78
7.4.120.0120.00417.01
7.4.110.0110.00716.79
7.4.100.0150.00816.65
7.4.90.0100.01017.01
7.4.80.0060.01019.39
7.4.70.0060.01016.81
7.4.60.0150.00316.82
7.4.50.0040.01116.72
7.4.40.0110.00516.71
7.4.00.0020.01515.79
7.3.330.0050.00013.87
7.3.320.0000.00613.91
7.3.310.0030.00316.66
7.3.300.0030.00316.90
7.3.290.0030.00316.91
7.3.280.0110.00816.62
7.3.260.0100.00816.83
7.3.240.0100.00916.89
7.3.230.0030.01416.82
7.3.210.0060.01116.97
7.3.200.0070.01016.79
7.3.190.0030.01316.90
7.3.180.0060.01016.79
7.3.170.0090.00616.86
7.3.160.0100.01216.89
7.3.120.0030.01515.75
7.3.110.0030.01415.24
7.3.100.0130.00015.35
7.3.90.0060.01215.55
7.3.80.0060.00915.23
7.3.70.0050.00915.49
7.3.60.0020.01315.52
7.3.50.0040.00615.47
7.3.40.0080.01015.17
7.3.30.0100.00515.17
7.3.20.0100.01016.21
7.3.10.0100.01016.34
7.3.00.0100.00516.16
7.2.330.0140.00316.84
7.2.320.0030.01317.27
7.2.310.0130.00316.87
7.2.300.0120.00916.87
7.2.290.0100.00616.82
7.2.250.0070.01015.83
7.2.240.0070.01015.75
7.2.230.0140.00715.98
7.2.220.0060.01215.46
7.2.210.0110.00315.98
7.2.200.0050.00915.65
7.2.190.0040.01115.60
7.2.180.0020.01115.58
7.2.170.0030.00915.48
7.2.160.0140.00715.45
7.2.150.0130.01015.50
7.2.140.1190.00715.41
7.2.130.0060.00915.26
7.2.120.0110.00715.34
7.2.110.0120.00615.46
7.2.100.0150.00315.57
7.2.90.0120.00615.72
7.2.80.0090.01015.73
7.2.70.0150.00315.22
7.2.60.0080.01115.66
7.2.50.0060.01215.70
7.2.40.0110.00715.43
7.2.30.0150.00915.46
7.2.20.0070.00715.67
7.2.10.0110.00315.30
7.2.00.0170.01015.32
7.1.330.0070.00716.18
7.1.320.0060.00616.16
7.1.310.0050.00516.34
7.1.300.0110.01115.27
7.1.290.0100.00615.28
7.1.280.0170.00915.26
7.1.270.0060.00915.35
7.1.260.0110.00515.41
7.1.250.0070.01014.45

preferences:
62.66 ms | 401 KiB | 5 Q