3v4l.org

run code in 300+ PHP versions simultaneously
<?php //http://www.onlineconversion.com/unix_time.htm function ei_decode($ei) { // Copyright 2013 Deed Poll Office Ltd, UK <https://deedpolloffice.com> // Licensed under Apache Licence v2.0 <http://apache.org/licenses/LICENSE-2.0> $ei = base64_decode(str_replace(array('_', '-'), array('+', '/'), $ei)); if (!preg_match('/^ (.{4}) ((?:[\x80-\xff]*[\0-\x7f])+) $/sx', $ei, $matches)) return false; // Non-valid ei value $ret = array(); $val = 0; foreach (str_split($matches[1]) as $i => $c) $val = PHP_INT_SIZE < 5 && function_exists('bcadd') ? bcadd($val, bcmul(ord($c), bcpow(2, $i * 8))) : $val + (ord($c) << $i * 8); $ret[0] = $val; preg_match_all('/[\x80-\xff]*[\0-\x7f]/', $matches[2], $matches, PREG_SET_ORDER); foreach ($matches as $j => $match) { $val = 0; foreach (str_split($match[0]) as $i => $c) $val = PHP_INT_SIZE < 8 && function_exists('bcadd') ? bcadd($val, bcmul(ord($c) & 0x7f, bcpow(2, $i * 7))) : $val + ((ord($c) & 0x7f) << $i * 7); $ret[$j + 1] = $val; } return $ret; } print_r(ei_decode('QWZ9VZS6GuSr7Abw4YLIAQ'));

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.0070.01416.75
8.3.50.0100.00821.23
8.3.40.0040.01118.96
8.3.30.0150.00719.21
8.3.20.0000.00820.19
8.3.10.0080.00021.76
8.3.00.0080.00019.68
8.2.180.0120.00918.79
8.2.170.0070.00719.09
8.2.160.0100.00722.96
8.2.150.0060.00324.18
8.2.140.0060.00324.66
8.2.130.0070.00026.16
8.2.120.0080.00019.66
8.2.110.0100.00022.32
8.2.100.0090.00317.84
8.2.90.0040.00418.34
8.2.80.0080.00018.05
8.2.70.0040.00418.00
8.2.60.0030.00817.93
8.2.50.0040.00418.07
8.2.40.0080.00020.20
8.2.30.0000.00819.95
8.2.20.0080.00018.05
8.2.10.0040.00418.17
8.2.00.0000.00818.16
8.1.280.0060.00925.92
8.1.270.0050.00320.37
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0060.00323.92
8.1.230.0040.00821.04
8.1.220.0080.00017.79
8.1.210.0080.00018.77
8.1.200.0100.00017.35
8.1.190.0030.00517.65
8.1.180.0040.00418.10
8.1.170.0070.00418.67
8.1.160.0000.00822.11
8.1.150.0050.00318.87
8.1.140.0040.00417.68
8.1.130.0000.00717.86
8.1.120.0000.00917.67
8.1.110.0040.00717.59
8.1.100.0030.00417.61
8.1.90.0000.00717.62
8.1.80.0070.00017.64
8.1.70.0070.00017.66
8.1.60.0060.00317.69
8.1.50.0000.00817.67
8.1.40.0000.00817.64
8.1.30.0060.00317.86
8.1.20.0000.00817.83
8.1.10.0030.00517.70
8.1.00.0040.00417.71
8.0.300.0040.00420.02
8.0.290.0030.00617.29
8.0.280.0000.00718.55
8.0.270.0000.00717.22
8.0.260.0000.00717.27
8.0.250.0030.00317.20
8.0.240.0040.00417.08
8.0.230.0070.00017.09
8.0.220.0030.00316.99
8.0.210.0040.00417.14
8.0.200.0000.00717.07
8.0.190.0020.00517.07
8.0.180.0050.00317.16
8.0.170.0030.00617.05
8.0.160.0050.00217.15
8.0.150.0000.00717.07
8.0.140.0080.00017.13
8.0.130.0050.00013.53
8.0.120.0050.00317.11
8.0.110.0080.00017.13
8.0.100.0030.00617.16
8.0.90.0030.00617.09
8.0.80.0120.00417.17
8.0.70.0040.00417.14
8.0.60.0000.00717.23
8.0.50.0000.00816.96
8.0.30.0090.00917.26
8.0.20.0110.01017.40
8.0.10.0040.00417.18
8.0.00.0150.00616.96
7.4.330.0050.00015.03
7.4.320.0040.00416.64
7.4.300.0000.00616.73
7.4.290.0040.00416.70
7.4.280.0080.00016.74
7.4.270.0030.00316.63
7.4.260.0030.00716.67
7.4.250.0000.00716.71
7.4.240.0000.00716.66
7.4.230.0000.00716.63
7.4.220.0060.01216.81
7.4.210.0070.01016.77
7.4.200.0070.00016.57
7.4.160.0070.00716.71
7.4.150.0030.01617.40
7.4.140.0130.01017.86
7.4.130.0060.01316.58
7.4.120.0100.01216.84
7.4.110.0110.00816.75
7.4.100.0140.00416.71
7.4.90.0090.00916.68
7.4.80.0130.00919.39
7.4.70.0100.00716.67
7.4.60.0060.01016.87
7.4.50.0030.00516.69
7.4.40.0090.00916.72
7.4.30.0070.01016.80
7.4.00.0070.00715.35
7.3.330.0040.00413.46
7.3.320.0000.00613.51
7.3.310.0000.00716.48
7.3.300.0070.00016.61
7.3.290.0110.00516.59
7.3.280.0100.00816.54
7.3.270.0120.00617.40
7.3.260.0100.01316.88
7.3.250.0070.01216.63
7.3.240.0060.01516.68
7.3.230.0110.00716.81
7.3.210.0030.01316.82
7.3.200.0120.00916.53
7.3.190.0000.01616.75
7.3.180.0030.01316.55
7.3.170.0070.01016.75
7.3.160.0070.01016.75
7.2.330.0100.00716.66
7.2.320.0030.01316.73
7.2.310.0180.00016.89
7.2.300.0120.00916.93
7.2.290.0120.01217.00
7.2.60.0090.00317.20
7.2.00.0060.00919.54
7.1.200.0030.01116.05
7.1.100.0060.00618.34
7.1.70.0000.00717.50
7.1.60.0120.00619.86
7.1.50.0000.01117.09
7.1.00.0000.08022.46
7.0.200.0030.00717.06
7.0.60.0300.07319.96
7.0.50.0070.04017.91
7.0.40.0100.04020.13
7.0.30.0170.04720.12
7.0.20.0300.08320.26
7.0.10.0130.08020.12
7.0.00.0070.08720.24
5.6.280.0030.07320.79
5.6.210.0030.04020.70
5.6.200.0070.05018.15
5.6.190.0070.08020.60
5.6.180.0300.07320.59
5.6.170.0370.07320.58
5.6.160.0100.04020.62
5.6.150.0130.06018.25
5.6.140.0030.06318.29
5.6.130.0100.08718.25
5.6.120.0100.06321.02
5.6.110.0100.06721.15
5.6.100.0170.04720.98
5.6.90.0070.06321.11
5.6.80.0100.07720.39
5.5.350.0300.06720.40
5.5.340.0070.08318.09
5.5.330.0130.03720.40
5.5.320.0200.04320.27
5.5.310.0230.03720.35
5.5.300.0100.08018.08
5.5.290.0070.08717.98
5.5.280.0030.04320.79
5.5.270.0130.05320.99
5.5.260.0070.07720.79
5.5.250.0170.06720.63
5.5.240.0000.04020.18
5.4.450.3700.04719.28
5.4.440.0000.08319.57
5.4.430.1630.07319.43
5.4.420.4370.03319.31
5.4.410.2900.04019.26
5.4.400.3230.03718.94
5.4.390.3170.04019.11
5.4.380.3370.03319.22
5.4.370.4030.04019.07
5.4.360.4000.03718.95
5.4.350.3800.04319.04
5.4.340.0030.06019.21
5.4.320.3970.04018.99
5.4.310.4270.04019.13
5.4.300.3530.04019.06
5.4.290.4100.03319.21
5.4.280.4100.04018.98
5.4.270.3900.03719.19
5.4.260.4800.05018.95
5.4.250.4570.04719.20
5.4.240.0070.07719.14
5.4.230.1300.05019.14
5.4.220.3870.03719.23
5.4.210.3830.03019.20
5.4.200.3870.03719.02
5.4.190.4570.03018.92
5.4.180.5370.04319.13
5.4.170.4000.03019.10
5.4.160.3570.04019.13
5.4.150.4030.04019.13
5.4.140.4730.02716.40
5.4.130.4300.03716.50
5.4.120.4430.03716.40
5.4.110.4070.04316.57
5.4.100.4530.04016.45
5.4.90.4470.03716.49
5.4.80.4600.03316.67
5.4.70.4670.03316.51
5.4.60.4570.03716.33
5.4.50.4630.02716.61
5.4.40.4530.03016.62
5.4.30.4600.03316.32
5.4.20.3530.03716.41
5.4.10.3970.03716.46
5.4.00.3500.03315.98
5.3.290.4100.04014.73
5.3.280.4330.03314.61
5.3.270.4270.03714.64
5.3.260.3670.04314.68
5.3.250.4230.03714.70
5.3.240.4400.04014.52
5.3.230.4300.03714.64
5.3.220.4570.03714.58
5.3.210.4100.04714.60
5.3.200.4130.03314.66
5.3.190.4630.04014.64
5.3.180.4500.03714.61
5.3.170.4530.04014.58
5.3.160.4630.03714.65
5.3.150.4630.03714.62
5.3.140.4930.04014.73
5.3.130.4730.03014.59
5.3.120.4070.03714.57
5.3.110.3970.04714.58
5.3.100.3930.03713.97
5.3.90.3930.03014.08
5.3.80.3670.03714.00
5.3.70.3570.04314.05
5.3.60.3800.03314.18
5.3.50.3730.04013.96
5.3.40.3600.03313.98
5.3.30.4370.04013.95
5.3.20.3770.03013.76
5.3.10.3800.03013.64
5.3.00.3800.04013.69
5.2.170.3100.03711.17
5.2.160.3000.03011.07
5.2.150.3530.03711.18
5.2.140.3200.03711.11
5.2.130.3170.02311.20
5.2.120.3430.02711.09
5.2.110.3500.03011.11
5.2.100.2870.03311.17
5.2.90.3430.03011.17
5.2.80.3370.03311.13
5.2.70.3400.03011.06
5.2.60.3500.02711.08
5.2.50.3800.03011.04
5.2.40.2500.02711.04
5.2.30.2770.03311.05
5.2.20.2370.03011.02
5.2.10.2470.02710.89
5.2.00.2100.03010.79
5.1.60.2130.03010.17
5.1.50.2730.02710.15
5.1.40.1700.0239.97
5.1.30.2430.02710.28
5.1.20.2430.02010.25
5.1.10.2730.02310.13
5.1.00.2500.02010.09
5.0.50.1270.0178.57
5.0.40.1200.0208.58
5.0.30.1200.0308.27
5.0.20.1230.0178.20
5.0.10.1230.0208.25
5.0.00.1330.0308.33
4.4.90.1670.0176.16
4.4.80.1170.0176.16
4.4.70.1400.0176.16
4.4.60.1200.0176.16
4.4.50.1230.0136.16
4.4.40.1230.0276.16
4.4.30.0970.0176.16
4.4.20.1200.0136.16
4.4.10.1330.0206.16
4.4.00.1430.0206.16
4.3.110.1200.0176.20
4.3.100.1200.0136.20
4.3.90.1200.0106.20
4.3.80.1170.0236.27
4.3.70.1430.0106.27
4.3.60.1430.0136.27
4.3.50.1570.0136.28
4.3.40.1670.0206.29
4.3.30.0600.0136.29
4.3.20.0730.0206.30
4.3.10.0830.0206.30
4.3.00.0870.0206.30

preferences:
62.29 ms | 401 KiB | 5 Q