3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * Created by PhpStorm. * User: Tobias Cervin * Date: 2017-10-02 */ session_start(); require_once 'Key.php'; if(isset($_POST['email']) && isset($_POST['key'])){ $email = $_POST['email']; $filename = 'subscriptions.txt'; if (!empty($email)){ if(Key::isValid($_POST['key'])){ //If key is valid it takes email from the form and writes it to the existing or created file 'subscriptions.txt' file_put_contents($filename, $email + '\n', FILE_APPEND | LOCK_EX); echo 'You have been added as a subscripteee!'; } else{ echo 'You little fraud, get out of here!!!'; } } else{ echo 'Wrong email input...'; } } ?> <!DOCTYPE html> <html> <head> <title>The Awesome Mail Spamming Subscription!</title> </head> <body> <form action="" method="post"> <div class="subscribe"> <strong>Please Subscribe!</strong> <div class="field"> eMail: <input type="email" name="email"> </div> <input type="submit" value="subscribed"> <input type="hidden" name="key" value="<?php echo Key::generate(); ?>"> </div> </form> </body> </html>

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.0180.00318.55
8.3.50.0140.00318.15
8.3.40.0090.00618.95
8.3.30.0060.00918.84
8.3.20.0040.00420.29
8.3.10.0040.00421.88
8.3.00.0080.00021.69
8.2.180.0060.00918.65
8.2.170.0120.00322.96
8.2.160.0110.00322.20
8.2.150.0000.00824.18
8.2.140.0000.00824.66
8.2.130.0080.00020.94
8.2.120.0040.00426.35
8.2.110.0000.01020.39
8.2.100.0110.00017.91
8.2.90.0030.00519.27
8.2.80.0030.00517.97
8.2.70.0090.00017.75
8.2.60.0000.00817.93
8.2.50.0050.00318.16
8.2.40.0040.00420.57
8.2.30.0000.00720.45
8.2.20.0000.00718.02
8.2.10.0000.00818.03
8.2.00.0050.00218.07
8.1.280.0150.00625.92
8.1.270.0000.00820.18
8.1.260.0100.00026.35
8.1.250.0030.00628.09
8.1.240.0070.00320.58
8.1.230.0040.00717.76
8.1.220.0080.00017.74
8.1.210.0050.00318.77
8.1.200.0090.00017.38
8.1.190.0000.00817.23
8.1.180.0070.00018.10
8.1.170.0000.00818.71
8.1.160.0030.00518.80
8.1.150.0000.00720.25
8.1.140.0040.00417.74
8.1.130.0030.00319.05
8.1.120.0040.00417.46
8.1.110.0000.00817.36
8.1.100.0000.00717.34
8.1.90.0040.00417.33
8.1.80.0040.00417.52
8.1.70.0000.00717.37
8.1.60.0040.00717.55
8.1.50.0080.00017.43
8.1.40.0040.00417.64
8.1.30.0090.00017.71
8.1.20.0080.00017.72
8.1.10.0030.00617.64
8.1.00.0080.00317.65
8.0.300.0040.00418.77
8.0.290.0060.00317.00
8.0.280.0030.00318.59
8.0.270.0000.00817.37
8.0.260.0030.00518.67
8.0.250.0000.00817.11
8.0.240.0000.00717.04
8.0.230.0050.00217.05
8.0.220.0030.00317.07
8.0.210.0030.00616.96
8.0.200.0030.00517.17
8.0.190.0050.00317.09
8.0.180.0000.00817.11
8.0.170.0020.00517.09
8.0.160.0000.00717.02
8.0.150.0030.00816.98
8.0.140.0030.00516.94
8.0.130.0060.00013.42
8.0.120.0030.00516.89
8.0.110.0080.00017.06
8.0.100.0030.00517.08
8.0.90.0040.00416.95
8.0.80.0110.00417.07
8.0.70.0000.00716.91
8.0.60.0000.00717.18
8.0.50.0000.00716.90
8.0.30.0100.00917.23
8.0.20.0120.00817.40
8.0.10.0040.00316.95
8.0.00.0110.00616.85
7.4.330.0030.00315.55
7.4.320.0000.00616.56
7.4.300.0000.00616.41
7.4.290.0000.00716.56
7.4.280.0040.00416.63
7.4.270.0030.00316.53
7.4.260.0030.00316.55
7.4.250.0080.00016.55
7.4.240.0050.00216.68
7.4.230.0050.00216.49
7.4.220.0120.00616.68
7.4.210.0030.01316.50
7.4.200.0040.00416.45
7.4.160.0070.00916.71
7.4.150.0070.01117.40
7.4.140.0140.00817.86
7.4.130.0040.01516.67
7.4.120.0120.01016.62
7.4.110.0140.00716.63
7.4.100.0110.00716.58
7.4.90.0140.00616.41
7.4.80.0150.00919.39
7.4.70.0130.00716.43
7.4.60.0140.00916.41
7.4.50.0110.00316.70
7.4.40.0080.00816.54
7.4.30.0080.00816.61
7.4.00.0070.00715.09
7.3.330.0030.00213.05
7.3.320.0000.00513.17
7.3.310.0030.00516.25
7.3.300.0000.00716.35
7.3.290.0070.01116.28
7.3.280.0090.00716.31
7.3.270.0110.00717.40
7.3.260.0140.00316.40
7.3.250.0110.01016.41
7.3.240.0100.00916.39
7.3.230.0150.00316.39
7.3.210.0090.00716.42
7.3.200.0160.00416.25
7.3.190.0090.00916.62
7.3.180.0160.00616.52
7.3.170.0090.00616.37
7.3.160.0030.01316.40
7.2.330.0040.01416.43
7.2.320.0070.01016.56
7.2.310.0100.01316.53
7.2.300.0120.00616.51
7.2.290.0130.00516.30
7.2.110.0190.01115.89
7.2.60.0070.00716.86
7.1.200.0040.00815.73
7.1.100.1570.00616.44
7.1.90.1320.01016.07
7.1.80.1650.01016.10
7.1.70.1940.00715.32
7.1.60.1420.01033.11
7.1.50.1270.00632.81
7.1.40.1400.00732.48
7.1.30.1490.00732.55
7.1.20.1300.01332.56
7.1.10.1090.00614.80
7.1.00.1320.00714.79
7.0.240.1790.00715.75
7.0.230.1320.00715.86
7.0.220.1260.00315.70
7.0.210.1040.00714.71
7.0.200.1280.00714.72
7.0.190.1310.00714.90
7.0.180.1280.01014.07
7.0.170.1410.01014.34
7.0.160.1380.01414.44
7.0.150.1250.00714.37
7.0.140.1320.01014.28
7.0.130.1190.00314.50
7.0.120.1770.01014.46
7.0.110.1610.00714.31
7.0.100.1780.00314.12
7.0.90.1280.00314.43
7.0.80.1110.01314.41
7.0.70.1170.00714.23
7.0.60.1630.01014.18
7.0.50.1320.00714.64
7.0.40.1340.00714.54
7.0.30.1100.00714.84
7.0.20.1220.01014.32
7.0.10.1320.01014.47
7.0.00.1130.00314.57

preferences:
57.95 ms | 401 KiB | 5 Q