3v4l.org

run code in 300+ PHP versions simultaneously
<?php $seconds = 2; $h = $seconds / 3600 % 24; $m = $seconds / 60 % 60; $s = $seconds % 60; $hours = '00'; $minutes = '00'; $seconds = '00'; if ($h > 0){ if (strlen(strval($h)) == 1){ $hours = '0'.strval($h); } } if ($m > 0){ if (strlen(strval($m)) == 1){ $minutes = '0'.strval($m); } } if ($s > 0){ if (strlen(strval($s)) == 1){ $seconds = '0'.strval($s); } } $time = $hours.":".$minutes.":".$seconds; echo $time;

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.0120.00918.66
8.3.30.0140.00018.98
8.3.20.0040.00420.30
8.3.10.0040.00423.65
8.3.00.0090.00317.50
8.2.170.0060.00922.96
8.2.160.0100.00320.29
8.2.150.0000.00824.18
8.2.140.0000.00824.66
8.2.130.0040.00426.16
8.2.120.0080.00022.20
8.2.110.0050.00522.21
8.2.100.0080.00417.91
8.2.90.0050.00319.22
8.2.80.0040.00417.97
8.2.70.0040.00417.63
8.2.60.0050.00317.80
8.2.50.0040.00418.07
8.2.40.0040.00418.34
8.2.30.0000.00817.96
8.2.20.0070.00017.55
8.2.10.0030.00519.78
8.2.00.0030.00717.79
8.1.270.0040.00422.18
8.1.260.0080.00026.35
8.1.250.0080.00028.09
8.1.240.0080.00023.98
8.1.230.0070.00419.22
8.1.220.0040.00417.74
8.1.210.0050.00318.77
8.1.200.0030.00617.35
8.1.190.0000.00817.39
8.1.180.0050.00318.10
8.1.170.0040.00418.59
8.1.160.0040.00422.01
8.1.150.0050.00218.64
8.1.140.0040.00417.45
8.1.130.0030.00317.83
8.1.120.0000.00717.40
8.1.110.0000.00817.44
8.1.100.0030.00517.43
8.1.90.0000.00717.44
8.1.80.0030.00317.50
8.1.70.0000.00717.41
8.1.60.0090.00317.63
8.1.50.0000.00717.52
8.1.40.0050.00317.52
8.1.30.0040.00417.62
8.1.20.0040.00417.67
8.1.10.0050.00217.46
8.1.00.0060.00317.33
8.0.300.0040.00418.77
8.0.290.0040.00417.03
8.0.280.0030.00518.48
8.0.270.0040.00417.16
8.0.260.0030.00317.13
8.0.250.0000.00616.86
8.0.240.0030.00616.86
8.0.230.0030.00316.92
8.0.220.0070.00016.93
8.0.210.0000.00716.87
8.0.200.0060.00017.01
8.0.190.0060.00316.97
8.0.180.0040.00416.95
8.0.170.0040.00416.81
8.0.160.0030.00316.81
8.0.150.0070.00016.80
8.0.140.0070.00016.73
8.0.130.0030.00313.33
8.0.120.0000.00816.88
8.0.110.0050.00216.79
8.0.100.0070.00016.98
8.0.90.0000.00716.93
8.0.80.0040.01216.86
8.0.70.0040.00416.88
8.0.60.0040.00416.85
8.0.50.0000.00716.88
8.0.30.0130.00817.10
8.0.20.0070.01017.41
8.0.10.0000.00717.04
8.0.00.0050.01216.96
7.4.330.0000.00515.00
7.4.320.0000.00616.43
7.4.300.0000.00716.59
7.4.290.0040.00716.61
7.4.280.0040.00216.59
7.4.270.0030.00316.50
7.4.260.0060.00016.53
7.4.250.0040.00416.47
7.4.240.0020.00516.50
7.4.230.0000.00616.57
7.4.220.0130.01316.44
7.4.210.0090.00716.55
7.4.200.0030.00316.57
7.4.190.0020.00516.46
7.4.160.0030.01316.63
7.4.150.0170.00317.40
7.4.140.0110.00717.86
7.4.130.0060.01316.52
7.4.120.0150.00616.59
7.4.110.0060.01216.48
7.4.100.0100.01016.59
7.4.90.0070.01416.50
7.4.80.0030.01519.39
7.4.70.0080.00916.64
7.4.60.0120.00316.48
7.4.50.0000.00916.43
7.4.40.0060.00922.77
7.4.30.0100.00616.40
7.4.10.0070.01414.50
7.4.00.0060.01014.80
7.3.330.0020.00213.06
7.3.320.0050.00013.05
7.3.310.0030.00516.46
7.3.300.0030.00316.29
7.3.290.0030.01016.30
7.3.280.0090.00916.28
7.3.270.0150.00617.40
7.3.260.0100.00716.46
7.3.250.0080.00816.35
7.3.240.0110.00616.36
7.3.230.0070.01116.39
7.3.210.0130.00316.58
7.3.200.0150.00619.39
7.3.190.0090.00816.49
7.3.180.0060.01316.26
7.3.170.0090.00616.48
7.3.160.0120.00416.49
7.3.130.0060.00915.11
7.3.120.0070.00714.90
7.3.110.0130.00514.79
7.3.100.0060.00814.64
7.3.90.0000.01414.88
7.3.80.0080.00714.81
7.3.70.0090.00314.79
7.3.60.0050.01014.86
7.3.50.0050.00914.73
7.3.40.0050.00814.80
7.3.30.0030.01014.93
7.3.20.0050.01116.58
7.3.10.0020.01516.68
7.3.00.0040.00816.71
7.2.330.0100.00716.64
7.2.320.0080.00816.51
7.2.310.0100.01016.76
7.2.300.0110.01116.50
7.2.290.0030.01216.71
7.2.260.0090.00615.09
7.2.250.0080.01215.06
7.2.240.0080.00714.97
7.2.230.0070.00914.92
7.2.220.0070.00714.83
7.2.210.0030.01215.14
7.2.200.0070.00615.18
7.2.190.0030.01214.98
7.2.180.0030.00815.12
7.2.170.0080.00815.11
7.2.160.0060.01214.95
7.2.150.0030.00616.93
7.2.140.0100.00316.83
7.2.130.0000.01416.81
7.2.120.0120.00016.92
7.2.110.0030.01316.50
7.2.100.0090.00616.50
7.2.90.0070.01016.83
7.2.80.0070.01016.98
7.2.70.0090.00616.84
7.2.60.0040.01117.06
7.2.50.0030.01316.91
7.2.40.0070.01016.71
7.2.30.0060.00616.77
7.2.20.0070.00416.79
7.2.10.0100.00616.92
7.2.00.0060.00618.06
7.1.330.0070.00715.62
7.1.320.0040.00915.49
7.1.310.0070.01015.65
7.1.300.0080.00615.77
7.1.290.0030.00815.79
7.1.280.0090.00315.85
7.1.270.0060.00815.55
7.1.260.0080.00515.90
7.1.250.0040.01115.91
7.1.240.0040.01515.83
7.1.230.0100.00715.30
7.1.220.0090.00615.52
7.1.210.0030.01415.49
7.1.200.0000.01715.45
7.1.190.0040.00715.80
7.1.180.0030.01015.54
7.1.170.0110.00415.73
7.1.160.0090.00615.82
7.1.150.0030.01015.34
7.1.140.0110.00715.60
7.1.130.0100.00615.62
7.1.120.0030.01015.64
7.1.110.0120.00015.50
7.1.100.0020.00916.54
7.1.90.0070.01015.60
7.1.80.0030.01015.30
7.1.70.0040.00716.46
7.1.60.0050.01417.55
7.1.50.0030.01516.23
7.1.40.0000.01315.24
7.1.30.0060.00915.86
7.1.20.0060.01015.53
7.1.10.0030.01215.45
7.1.00.0060.04219.07
7.0.330.0040.01415.41
7.0.320.0070.00415.33
7.0.310.0030.01015.49
7.0.300.0100.00714.96
7.0.290.0070.00714.99
7.0.280.0040.00815.11
7.0.270.0080.00615.16
7.0.260.0040.00814.80
7.0.250.0070.00715.02
7.0.240.0030.01315.50
7.0.230.0030.00615.10
7.0.220.0070.00415.12
7.0.210.0030.00715.51
7.0.200.0100.00615.99
7.0.190.0030.00715.42
7.0.180.0040.00715.40
7.0.170.0030.00915.28
7.0.160.0030.00815.45
7.0.150.0040.00815.15
7.0.140.0070.03818.61
7.0.130.0000.01015.50
7.0.120.0000.01415.52
7.0.110.0040.00715.21
7.0.100.0080.00015.41
7.0.90.0070.01015.48
7.0.80.0340.03617.55
7.0.70.0240.02217.55
7.0.60.0280.04017.80
7.0.50.0260.02618.02
7.0.40.0020.03516.58
7.0.30.0080.04116.77
7.0.20.0050.02816.84
7.0.10.0050.03316.74
7.0.00.0060.03116.73
5.6.400.0030.00614.59
5.6.390.0090.00914.51
5.6.380.0100.00014.32
5.6.370.0070.00714.21
5.6.360.0070.00314.36
5.6.350.0080.00514.28
5.6.340.0030.01014.25
5.6.330.0060.00614.18
5.6.320.0090.00614.36
5.6.310.0120.00413.89
5.6.300.0120.00914.54
5.6.290.0040.01214.35
5.6.280.0030.04117.65
5.6.270.0070.00714.49
5.6.260.0000.00914.47
5.6.250.0030.01314.00
5.6.240.0060.00914.17
5.6.230.0030.04417.49
5.6.220.0050.04817.48
5.6.210.0090.04117.43
5.6.200.0120.04017.70
5.6.190.0070.02217.55
5.6.180.0070.04317.43
5.6.170.0050.04617.41
5.6.160.0100.04217.47
5.6.150.0100.03717.58
5.6.140.0120.04317.71
5.6.130.0140.04017.54
5.6.120.0050.04617.75
5.6.110.0110.03617.51
5.6.100.0030.04617.65
5.6.90.0050.04317.58
5.6.80.0100.03517.33
5.6.70.0080.04017.10
5.6.60.0020.03817.18
5.6.50.0050.02417.25
5.6.40.0070.02717.30
5.6.30.0070.04216.95
5.6.20.0040.03117.21
5.6.10.0050.04517.26
5.6.00.0020.03617.02
5.5.380.0070.00714.11
5.5.370.0080.04217.42
5.5.360.0100.03817.37
5.5.350.0120.04217.20
5.5.340.0050.02717.50
5.5.330.0020.03717.54
5.5.320.0120.03717.44
5.5.310.0070.04717.46
5.5.300.0080.04317.58
5.5.290.0050.04417.49
5.5.280.0050.04217.44
5.5.270.0070.04417.50
5.5.260.0090.04217.44
5.5.250.0080.04417.48
5.5.240.0060.02817.02
5.5.230.0020.04517.23
5.5.220.0080.02017.26
5.5.210.0070.02217.06
5.5.200.0070.03717.18
5.5.190.0050.02617.18
5.5.180.0090.02917.20
5.5.170.0040.00714.09
5.5.160.0040.04217.23
5.5.150.0100.03617.12
5.5.140.0030.02817.27
5.5.130.0030.04417.30
5.5.120.0010.02817.24
5.5.110.0020.03417.29
5.5.100.0050.04217.25
5.5.90.0060.03817.12
5.5.80.0050.04517.16
5.5.70.0150.03717.18
5.5.60.0070.04017.06
5.5.50.0050.04317.11
5.5.40.0060.03817.14
5.5.30.0070.04317.10
5.5.20.0100.03917.19
5.5.10.0100.02217.00
5.5.00.0130.03817.11
5.4.450.0060.04315.06
5.4.440.0030.02915.24
5.4.430.0030.03715.13
5.4.420.0020.02615.19
5.4.410.0020.02415.22
5.4.400.0020.03414.92
5.4.390.0060.04014.87
5.4.380.0070.03915.07
5.4.370.0030.02215.04
5.4.360.0020.04515.01
5.4.350.0020.04615.02
5.4.340.0050.04215.06
5.4.330.0090.00010.71
5.4.320.0050.04315.05
5.4.310.0050.04515.00
5.4.300.0040.02214.75
5.4.290.0090.03514.82
5.4.280.0060.03814.82
5.4.270.0050.03814.93
5.4.260.0040.03215.13
5.4.250.0050.03614.82
5.4.240.0070.02315.03
5.4.230.0020.03714.96
5.4.220.0020.03314.79
5.4.210.0030.04215.20
5.4.200.0030.04514.97
5.4.190.0060.02614.96
5.4.180.0100.03614.91
5.4.170.0050.04114.91
5.4.160.0030.03715.06
5.4.150.0080.03514.97
5.4.140.0080.03513.72
5.4.130.0030.02413.50
5.4.120.0000.04613.63
5.4.110.0060.04013.68
5.4.100.0070.03713.59
5.4.90.0070.03713.47
5.4.80.0100.03513.58
5.4.70.0070.03813.52
5.4.60.0060.04113.50
5.4.50.0050.04013.69
5.4.40.0040.02413.67
5.4.30.0050.03413.64
5.4.20.0080.03713.49
5.4.10.0050.03313.60
5.4.00.0070.03713.32
5.3.290.0030.04212.55
5.3.280.0050.04012.48
5.3.270.0050.03312.53
5.3.260.0030.03712.50
5.3.250.0100.03512.48
5.3.240.0070.03712.33
5.3.230.0050.04312.51
5.3.220.0080.03512.41
5.3.210.0070.04412.47
5.3.200.0080.03612.43
5.3.190.0080.03812.42
5.3.180.0040.02912.53
5.3.170.0080.03812.43
5.3.160.0070.02712.56
5.3.150.0030.04212.54
5.3.140.0080.03912.47
5.3.130.0080.03612.47
5.3.120.0050.04012.45
5.3.110.0050.04012.48
5.3.100.0070.04212.24
5.3.90.0050.03512.25
5.3.80.0070.03712.21
5.3.70.0050.04512.20
5.3.60.0050.03912.20
5.3.50.0000.04612.22
5.3.40.0050.03812.19
5.3.30.0120.03512.26
5.3.20.0080.03612.15
5.3.10.0060.03012.15
5.3.00.0020.02312.03
5.2.170.0030.04014.10
5.2.160.0000.06714.10
5.2.150.0030.06314.10
5.2.140.0030.04014.10
5.2.130.0030.05314.10
5.2.120.0000.06714.10
5.2.110.0100.06014.10
5.2.100.0100.04714.10
5.2.90.0070.06314.10
5.2.80.0100.04314.10
5.2.70.0070.06014.10
5.2.60.0030.06314.10
5.2.50.0030.06714.10
5.2.40.0030.05714.10
5.2.30.0100.05714.10
5.2.20.0030.05714.10
5.2.10.0070.06014.10
5.2.00.0000.05014.10
5.1.60.0100.03014.10
5.1.50.0030.04014.10
5.1.40.0100.02314.10
5.1.30.0000.05714.10
5.1.20.0100.03314.10
5.1.10.0070.05014.10
5.1.00.0070.04314.10
5.0.50.0030.04314.10
5.0.40.0000.03014.10
5.0.30.0070.06714.10
5.0.20.0000.03314.10
5.0.10.0000.04314.10
5.0.00.0030.05314.10
4.4.90.0030.03314.10
4.4.80.0070.02714.10
4.4.70.0030.02314.10
4.4.60.0070.02314.10
4.4.50.0000.03714.10
4.4.40.0000.03314.10
4.4.30.0030.03714.10
4.4.20.0000.04014.10
4.4.10.0030.03714.10
4.4.00.0030.05014.10
4.3.110.0030.03014.10
4.3.100.0030.03014.10
4.3.90.0070.03314.10
4.3.80.0130.04314.10
4.3.70.0030.02014.10
4.3.60.0030.03714.10
4.3.50.0030.02314.10
4.3.40.0000.05314.10
4.3.30.0000.03714.10
4.3.20.0000.03314.10
4.3.10.0030.03314.10
4.3.00.0000.03714.10

preferences:
39.6 ms | 400 KiB | 5 Q