3v4l.org

run code in 300+ PHP versions simultaneously
<?php function timePassed($time){ $time = time() - $time; $tokens = array ( 31536000 => 'year', 2592000 => 'month', 604800 => 'week', 86400 => 'day', 3600 => 'hour', 60 => 'minute', 1 => 'second' ); foreach ($tokens as $unit => $text) { if ($time < $unit) continue; $numberOfUnits = floor($time / $unit); return $numberOfUnits.' '.$text.(($numberOfUnits>1)?'s':''); } } timePassed('2014-04-03 19:21:30');

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)
7.4.10.0110.00815.73
7.4.00.0100.00615.59
7.3.130.0090.00915.64
7.3.120.0100.00815.54
7.3.110.0090.00915.43
7.3.100.0050.00915.50
7.3.90.0050.01015.45
7.3.80.0050.00815.60
7.3.70.0060.00715.43
7.3.60.0060.00615.34
7.3.50.0080.00615.35
7.3.40.0050.00715.29
7.3.30.0070.00615.33
7.3.20.0050.00917.33
7.3.10.0060.00817.08
7.3.00.0060.00617.04
7.2.260.0060.01315.91
7.2.250.0080.01115.59
7.2.240.0090.00615.61
7.2.230.0040.01015.51
7.2.220.0080.00715.53
7.2.210.0060.00615.71
7.2.200.0060.00915.54
7.2.190.0040.00715.65
7.2.180.0030.01215.64
7.2.170.0040.00915.56
7.2.160.0050.00815.85
7.2.150.0050.01017.53
7.2.140.0030.00917.68
7.2.130.0050.00717.54
7.2.120.0040.00717.44
7.2.110.0040.00817.45
7.2.100.0080.00617.48
7.2.90.0060.00917.46
7.2.80.0070.00417.55
7.2.70.0090.00717.44
7.2.60.0060.00817.34
7.2.50.0030.01017.50
7.2.40.0080.00917.46
7.2.30.0040.01117.54
7.2.20.0050.00917.47
7.2.10.0080.00517.52
7.2.00.0030.01117.84
7.1.330.0090.00616.37
7.1.320.0080.00316.40
7.1.310.0070.00516.41
7.1.300.0080.00416.31
7.1.290.0090.00416.48
7.1.280.0030.00916.36
7.1.270.0040.01016.38
7.1.260.0070.00516.35
7.1.250.0060.00416.42
7.1.240.0070.00516.20
7.1.230.0060.00516.26
7.1.220.0060.00516.35
7.1.210.0040.00716.27
7.1.200.0040.00716.18
7.1.190.0030.00916.39
7.1.180.0060.00516.45
7.1.170.0060.00516.22
7.1.160.0020.01316.30
7.1.150.0040.01116.19
7.1.140.0050.00716.27
7.1.130.0090.00316.33
7.1.120.0030.01116.41
7.1.110.0070.00416.24
7.1.100.0080.00516.70
7.1.90.0040.00516.17
7.1.80.0030.00916.32
7.1.70.0040.00816.52
7.1.60.0050.01117.24
7.1.50.0060.00716.47
7.1.40.0060.00616.30
7.1.30.0040.00916.35
7.1.20.0010.01116.29
7.1.10.0080.00716.39
7.1.00.0050.02517.85
7.0.330.0060.00515.90
7.0.320.0050.00916.00
7.0.310.0040.00815.88
7.0.300.0070.00715.77
7.0.290.0050.01215.94
7.0.280.0090.00715.98
7.0.270.0030.00715.95
7.0.260.0050.00715.95
7.0.250.0040.00916.06
7.0.240.0050.00916.07
7.0.230.0040.00915.97
7.0.220.0050.00615.95
7.0.210.0040.00816.04
7.0.200.0050.00816.16
7.0.190.0100.00516.03
7.0.180.0050.00715.79
7.0.170.0070.00715.94
7.0.160.0030.00916.03
7.0.150.0040.00815.92
7.0.140.0070.02217.54
7.0.130.0060.00716.11
7.0.120.0050.00815.88
7.0.110.0030.00916.11
7.0.100.0040.02316.98
7.0.90.0120.02716.95
7.0.80.0150.02516.97
7.0.70.0140.01917.01
7.0.60.0150.02416.92
7.0.50.0160.02317.01
7.0.40.0040.02815.50
7.0.30.0090.02315.48
7.0.20.0080.01615.48
7.0.10.0080.02215.54
7.0.00.0050.02615.49
5.6.400.0060.00815.22
5.6.390.0060.00615.26
5.6.380.0040.00914.92
5.6.370.0050.00914.82
5.6.360.0070.00814.94
5.6.350.0020.01115.03
5.6.340.0050.00914.92
5.6.330.0050.01114.94
5.6.320.0050.01114.74
5.6.310.0100.00414.99
5.6.300.0030.01114.95
5.6.290.0040.01014.68
5.6.280.0050.02516.38
5.6.270.0060.00714.87
5.6.260.0080.00714.74
5.6.250.0030.02616.22
5.6.240.0050.02216.43
5.6.230.0060.02616.36
5.6.220.0030.01716.33
5.6.210.0030.02016.25
5.6.200.0050.01616.34
5.6.190.0040.02716.48
5.6.180.0080.02516.33
5.6.170.0090.01616.29
5.6.160.0060.02416.40
5.6.150.0070.02716.47
5.6.140.0080.01716.49
5.6.130.0070.02516.40
5.6.120.0040.02216.43
5.6.110.0070.02816.45
5.6.100.0080.02116.29
5.6.90.0040.02816.33
5.6.80.0060.02516.23
5.6.70.0060.02716.22
5.6.60.0090.02316.09
5.6.50.0090.01516.20
5.6.40.0070.02616.13
5.6.30.0060.01616.22
5.6.20.0040.02516.20
5.6.10.0030.02716.22
5.6.00.0050.02316.22
5.5.380.0060.02115.38
5.5.370.0040.01815.44
5.5.360.0070.02415.42
5.5.350.0040.02815.52
5.5.340.0030.02815.36
5.5.330.0050.02415.53
5.5.320.0070.02215.46
5.5.310.0030.01715.52
5.5.300.0060.02715.56
5.5.290.0080.02215.56
5.5.280.0050.02515.54
5.5.270.0060.02415.64
5.5.260.0060.02015.49
5.5.250.0060.02615.37
5.5.240.0090.01415.38
5.5.230.0040.02715.37
5.5.220.0030.02215.16
5.5.210.0060.02515.37
5.5.200.0080.02115.19
5.5.190.0080.01515.38
5.5.180.0060.02815.38
5.5.170.0050.00813.74
5.5.160.0040.02715.22
5.5.150.0040.01915.32
5.5.140.0080.02215.23
5.5.130.0040.01815.41
5.5.120.0090.02115.39
5.5.110.0050.02615.40
5.5.100.0030.02815.25
5.5.90.0040.02815.22
5.5.80.0030.02715.29
5.5.70.0030.02615.31
5.5.60.0080.01815.29
5.5.50.0040.02715.32
5.5.40.0070.02315.32
5.5.30.0070.01415.38
5.5.20.0100.02115.26
5.5.10.0070.02715.26
5.5.00.0030.01715.07
5.4.450.0020.02713.98
5.4.440.0040.02614.01
5.4.430.0050.02214.10
5.4.420.0060.02114.03
5.4.410.0080.01814.02
5.4.400.0040.02313.85
5.4.390.0050.02413.86
5.4.380.0070.01713.94
5.4.370.0060.01913.99
5.4.360.0060.02213.91
5.4.350.0040.02413.85
5.4.340.0040.01513.91
5.4.330.0050.00412.14
5.4.320.0040.02514.01
5.4.310.0070.02013.83
5.4.300.0050.01813.93
5.4.290.0050.01413.98
5.4.280.0060.02013.76
5.4.270.0040.02313.96
5.4.260.0070.02013.96
5.4.250.0080.02013.90
5.4.240.0050.02313.81
5.4.230.0070.02013.89
5.4.220.0040.01613.85
5.4.210.0060.02213.90
5.4.200.0050.01813.90
5.4.190.0060.01913.86
5.4.180.0060.01813.82
5.4.170.0030.01713.80
5.4.160.0100.01813.78
5.4.150.0070.01713.80
5.4.140.0090.01613.34
5.4.130.0070.02213.29
5.4.120.0060.01413.23
5.4.110.0070.01613.20
5.4.100.0030.02413.25
5.4.90.0050.02413.29
5.4.80.0030.01413.20
5.4.70.0080.01213.26
5.4.60.0060.01913.12
5.4.50.0020.01713.27
5.4.40.0040.02113.17
5.4.30.0020.02713.26
5.4.20.0080.01713.20
5.4.10.0060.02213.27
5.4.00.0080.01713.08
5.3.290.0040.02012.83
5.3.280.0050.02412.82
5.3.270.0040.02412.84
5.3.260.0050.01612.86
5.3.250.0030.02312.80
5.3.240.0050.02212.84
5.3.230.0020.02212.83
5.3.220.0070.01112.77
5.3.210.0010.02812.83
5.3.200.0050.02312.78
5.3.190.0040.01712.79
5.3.180.0030.02312.90
5.3.170.0030.01812.94
5.3.160.0070.01812.80
5.3.150.0060.02212.86
5.3.140.0040.02312.86
5.3.130.0040.01812.77
5.3.120.0060.02212.84
5.3.110.0060.02312.86
5.3.100.0060.01912.86
5.3.90.0040.01812.80
5.3.80.0050.01312.78
5.3.70.0050.01512.77
5.3.60.0050.01612.83
5.3.50.0060.02212.87
5.3.40.0050.02512.84
5.3.30.0040.02112.84
5.3.20.0020.02512.77
5.3.10.0030.02212.68
5.3.00.0060.01612.75
5.2.170.0100.02712.19
5.2.160.0010.02612.21
5.2.150.0070.02912.15
5.2.140.0060.03312.18
5.2.130.0040.02012.17
5.2.120.0040.02012.20
5.2.110.0000.03712.17
5.2.100.0070.03112.18
5.2.90.0050.02412.11
5.2.80.0050.03311.91
5.2.70.0080.03012.09
5.2.60.0030.02812.03
5.2.50.0070.03212.09
5.2.40.0050.02512.06
5.2.30.0050.03311.96
5.2.20.0020.03412.09
5.2.10.0090.02012.01
5.2.00.0110.02311.99
5.1.60.0030.02911.66
5.1.50.0050.02711.55
5.1.40.0040.02111.73
5.1.30.0040.03111.79
5.1.20.0040.02711.72
5.1.10.0020.03111.77
5.1.00.0080.02611.68
5.0.50.0030.02411.25
5.0.40.0040.01811.25
5.0.30.0000.03911.25
5.0.20.0060.01311.25
5.0.10.0020.02311.25
5.0.00.0010.03111.25
4.4.90.0010.02011.25
4.4.80.0030.01711.25
4.4.70.0030.01511.25
4.4.60.0030.01311.25
4.4.50.0030.01511.25
4.4.40.0100.02311.25
4.4.30.0050.01711.25
4.4.20.0050.01711.25
4.4.10.0000.02011.25
4.4.00.0060.01611.25
4.3.110.0030.01911.25
4.3.100.0020.01311.25
4.3.90.0040.01811.25
4.3.80.0030.03011.25
4.3.70.0000.02311.25
4.3.60.0000.02111.25
4.3.50.0030.02211.25
4.3.40.0030.02711.25
4.3.30.0010.02011.25
4.3.20.0040.01811.25
4.3.10.0020.02011.25
4.3.00.0010.01111.25

preferences:
40.12 ms | 400 KiB | 5 Q