3v4l.org

run code in 300+ PHP versions simultaneously
<?php include 'token.php'; require_once 'api/CManager.php'; $Manager = new \teachme\CManager(); $DB = $Manager->GetDB(); if(!$Manager->Valid()) { header("X-API-Status: 40002 Invalid Manager"); die(); } if(preg_match("/^(?:[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9](?:[a-zA-Z0-9\-](?!\.)){0,61}[a-zA-Z0-9]?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9\-](?!$)){0,61}[a-zA-Z0-9]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/", $_POST["mail"]) != 1) { header("X-API-Status: 44003 Mail invalid"); die(); } if($Manager->GetUsers("WHERE `".$DB["Tables"]["Users"]["Mail"]."` LIKE '".$Manager->EscapeString($_POST["mail"])."'") !== FALSE) { header("X-API-Status: 44004 Mail exists"); die(); } $Entry = new \teachme\CUser(); $Entry->SetName($_POST["name"]); $Entry->SetMail($_POST["mail"]); if(isset($_POST["password"]) && strlen($_POST["password"]) > 0) { $Entry->SetPassword($_POST["password"]); } if(strpos($Client["OS"], "iOS") !== FALSE) { $_POST["offers"] = explode($iOSDelimiter, $_POST["offers"]); $_POST["requests"] = explode($iOSDelimiter, $_POST["requests"]); } $Entry->SetPhone($_POST["phone"]); $Entry->SetUniversity($_POST["university"]); $Entry->SetOffers("µ".implode("µµ", $_POST["offers"])."µ"); $Entry->SetRequests("µ".implode("µµ", $_POST["requests"])."µ"); $Entry->SetPriceOffer($_POST["priceoffer"]); $Entry->SetPriceRequest($_POST["pricerequest"]); $Entry->SetBirthday($_POST["birthday"]); $Entry->SetGender($_POST["gender"]); $Entry->SetSemester($_POST["semester"]); $Entry->SetAbout($_POST["about"]); $Entry->SetTimes($_POST["times"]); $Entry->SetLastActivity(now()); $Entry->SetRegistration(now()); $Entry->SetActive(1); if(!$Manager->Save($Entry)) { header("X-API-Status: 44002 Saving Failed"); die(); } if(($User = $Manager->GetUsers("WHERE `".$DB["Tables"]["Users"]["Mail"]."` LIKE '".$Manager->EscapeString($_POST["mail"])."'")) !== false) { $Entry = $User[0]; } $_SESSION["TeachMe-Server"]["loggedin"] = true; $_SESSION["TeachMe-Server"]["User"] = $Entry->ToArray(); PrintResult($Entry->ToArray()); ?>

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.0090.00618.30
8.3.50.0120.00422.04
8.3.40.0120.00619.00
8.3.30.0140.00019.17
8.3.20.0040.00420.27
8.3.10.0090.00020.59
8.3.00.0080.00019.51
8.2.180.0130.00916.85
8.2.170.0120.00322.96
8.2.160.0110.00420.65
8.2.150.0040.00424.18
8.2.140.0100.00324.66
8.2.130.0040.00426.16
8.2.120.0000.00820.99
8.2.110.0070.00320.47
8.2.100.0080.00418.22
8.2.90.0040.00419.25
8.2.80.0040.00417.97
8.2.70.0000.01017.63
8.2.60.0050.00917.68
8.2.50.0070.00418.07
8.2.40.0000.00818.47
8.2.30.0000.00819.54
8.2.20.0040.00417.86
8.2.10.0040.00418.05
8.2.00.0000.00817.73
8.1.280.0140.00725.92
8.1.270.0120.00622.36
8.1.260.0050.00326.35
8.1.250.0050.00328.09
8.1.240.0060.00322.18
8.1.230.0090.00317.77
8.1.220.0000.00917.91
8.1.210.0040.00418.77
8.1.200.0040.00817.48
8.1.190.0000.00917.47
8.1.180.0000.00818.10
8.1.170.0080.00018.62
8.1.160.0040.00422.24
8.1.150.0050.00318.97
8.1.140.0000.00717.50
8.1.130.0000.00717.91
8.1.120.0040.00417.44
8.1.110.0000.00717.54
8.1.100.0030.00517.54
8.1.90.0040.00417.46
8.1.80.0000.00717.46
8.1.70.0030.00317.46
8.1.60.0000.00917.57
8.1.50.0030.00517.62
8.1.40.0030.00517.63
8.1.30.0030.00617.70
8.1.20.0000.00917.81
8.1.10.0040.00417.74
8.1.00.0000.00817.66
8.0.300.0080.00018.77
8.0.290.0040.00416.88
8.0.280.0040.00418.54
8.0.270.0000.00717.35
8.0.260.0070.00017.29
8.0.250.0070.00017.21
8.0.240.0000.00717.18
8.0.230.0030.00317.25
8.0.220.0030.00317.15
8.0.210.0000.00716.99
8.0.200.0040.00417.18
8.0.190.0070.00017.19
8.0.180.0080.00017.16
8.0.170.0000.00817.04
8.0.160.0070.00017.00
8.0.150.0000.00717.00
8.0.140.0070.00017.08
8.0.130.0030.00313.48
8.0.120.0090.00017.07
8.0.110.0040.00417.08
8.0.100.0030.00517.06
8.0.90.0050.00217.03
8.0.80.0030.01317.09
8.0.70.0080.00017.16
8.0.60.0080.00017.19
8.0.50.0030.00516.92
8.0.30.0060.01517.30
8.0.20.0150.00717.44
8.0.10.0070.00017.13
8.0.00.0120.00616.83
7.4.330.0050.00015.00
7.4.320.0030.00316.63
7.4.300.0060.00016.58
7.4.290.0050.00216.62
7.4.280.0080.00016.75
7.4.270.0000.00716.77
7.4.260.0000.00716.49
7.4.250.0040.00416.56
7.4.240.0040.00316.67
7.4.230.0030.00316.73
7.4.220.0120.00616.58
7.4.210.0090.01216.58
7.4.200.0030.00416.71
7.4.160.0210.00716.45
7.4.150.0120.01017.40
7.4.140.0070.01117.86
7.4.130.0090.01116.67
7.4.120.0140.00716.68
7.4.110.0080.01216.42
7.4.100.0110.00816.77
7.4.90.0070.01016.52
7.4.80.0120.00619.39
7.4.70.0120.00616.52
7.4.60.0110.00716.38
7.4.50.0030.00516.54
7.4.40.0050.01116.76
7.4.30.0100.00616.43
7.4.00.0080.00814.96
7.3.330.0030.00313.28
7.3.320.0030.00313.36
7.3.310.0040.00416.44
7.3.300.0070.00016.29
7.3.290.0120.00316.37
7.3.280.0090.00716.41
7.3.270.0140.00417.40
7.3.260.0130.01316.47
7.3.250.0130.00416.64
7.3.240.0140.00716.50
7.3.230.0030.01316.50
7.3.210.0100.00716.46
7.3.200.0120.00919.39
7.3.190.0060.01216.27
7.3.180.0130.00316.48
7.3.170.0100.01216.43
7.3.160.0030.01916.37
7.3.10.0040.01116.61
7.3.00.0100.00316.67
7.2.330.0080.00816.69
7.2.320.0070.01116.42
7.2.310.0130.00716.70
7.2.300.0070.01016.55
7.2.290.0080.00816.76
7.2.130.0060.00916.58
7.2.120.0000.01016.71
7.2.110.0030.01316.72
7.2.100.0040.01116.59
7.2.90.0110.00416.73
7.2.80.0070.01016.86
7.2.70.0030.01016.82
7.2.60.0090.00616.63
7.2.50.0070.01016.68
7.2.40.0060.00616.87
7.2.30.0030.01016.68
7.2.20.0060.00916.59
7.2.10.0070.00316.82
7.2.00.0030.01416.95
7.1.250.0100.00715.64
7.1.70.0090.00617.06
7.1.60.0120.01219.61
7.1.50.0000.02216.89
7.1.00.0070.07322.49
7.0.200.0030.00616.31
7.0.140.0070.07022.00
7.0.60.0030.04319.98
7.0.50.0070.07717.91
7.0.40.0100.08320.30
7.0.30.0500.03720.18
7.0.20.0330.04320.16
7.0.10.0000.04720.10
7.0.00.0130.06020.31
5.6.280.0100.07021.12
5.6.210.0030.04320.65
5.6.200.0130.08318.23
5.6.190.0030.08720.28
5.6.180.0200.04720.58
5.6.170.0270.06020.52
5.6.160.0070.04020.52
5.6.150.0070.03718.14
5.6.140.0130.05018.26
5.6.130.0100.03318.17
5.6.120.0030.04321.14
5.6.110.0070.05721.14
5.6.100.0070.08321.03
5.6.90.0000.04720.97
5.6.80.0200.06320.51
5.6.70.3370.03320.55
5.5.350.0370.06720.50
5.5.340.0070.07317.97
5.5.330.0130.08320.24
5.5.320.0300.05020.19
5.5.310.0300.06320.22
5.5.300.0030.04018.04
5.5.290.0030.04317.99
5.5.280.0100.04320.79
5.5.270.0130.08020.77
5.5.260.0100.08320.79
5.5.250.0030.08320.52
5.5.240.0230.07320.06
5.4.450.0270.04319.22
5.4.440.0370.04719.38
5.4.430.0130.04319.21
5.4.420.0500.03019.58
5.4.410.0470.03719.29
5.4.400.0670.03719.11
5.4.390.0330.03318.82
5.4.380.0200.05318.65
5.4.370.0970.04018.73
5.4.360.0870.04718.68
5.4.350.0900.05318.58
5.4.340.0330.06018.68
5.4.320.0060.04112.50
5.4.310.0050.04112.50
5.4.300.0070.03612.50
5.4.290.0050.04012.49
5.4.280.0060.03612.39
5.4.270.0090.03612.39
5.4.260.0060.03912.39
5.4.250.0050.04012.39
5.4.240.0070.03712.39
5.4.230.0100.03312.39
5.4.220.0110.03812.39
5.4.210.0070.03412.38
5.4.200.0110.03212.39
5.4.190.0060.03612.38
5.4.180.0060.04112.38
5.4.170.0060.03612.40
5.4.160.0070.03512.39
5.4.150.0080.03412.38
5.4.140.0070.03612.07
5.4.130.0070.03312.05
5.4.120.0070.03712.01
5.4.110.0090.03712.01
5.4.100.0050.04012.02
5.4.90.0040.03812.01
5.4.80.0070.03512.02
5.4.70.0070.04112.01
5.4.60.0060.04012.01
5.4.50.0100.03612.00
5.4.40.0040.04012.00
5.4.30.0040.03711.99
5.4.20.0040.03811.99
5.4.10.0060.03511.99
5.4.00.0070.04311.48
5.3.290.0050.04212.80
5.3.280.0060.03812.71
5.3.270.0060.04312.73
5.3.260.0080.03812.71
5.3.250.0060.04212.72
5.3.240.0100.03612.72
5.3.230.0100.03612.71
5.3.220.0050.03912.68
5.3.210.0060.04512.68
5.3.200.0080.03512.68
5.3.190.0050.04312.68
5.3.180.0070.03612.68
5.3.170.0030.03912.67
5.3.160.0070.03712.68
5.3.150.0090.04112.68
5.3.140.0070.04012.66
5.3.130.0070.03812.66
5.3.120.0060.04012.66
5.3.110.0050.04112.66
5.3.100.0050.03812.14
5.3.90.0050.03712.12
5.3.80.0080.03412.11
5.3.70.0080.04812.10
5.3.60.0060.03712.09
5.3.50.0140.03412.04
5.3.40.0090.04012.06
5.3.30.0060.03512.00
5.3.20.0050.03611.78
5.3.10.0070.03411.74
5.3.00.0070.03611.73
5.2.170.0050.0309.18
5.2.160.0060.0299.19
5.2.150.0080.0339.19
5.2.140.0060.0379.18
5.2.130.0040.0299.14
5.2.120.0080.0339.14
5.2.110.0110.0289.15
5.2.100.0050.0339.15
5.2.90.0050.0289.14
5.2.80.0090.0269.13
5.2.70.0060.0319.14
5.2.60.0040.0329.10
5.2.50.0050.0399.07
5.2.40.0070.0309.04
5.2.30.0070.0299.01
5.2.20.0050.0299.01
5.2.10.0060.0278.93
5.2.00.0050.0308.78
5.1.60.0040.0288.07
5.1.50.0030.0268.07
5.1.40.0040.0258.05
5.1.30.0020.0288.40
5.1.20.0080.0228.43
5.1.10.0060.0328.15
5.1.00.0110.0238.15
5.0.50.0030.0226.62
5.0.40.0040.0266.48
5.0.30.0040.0316.29
5.0.20.0040.0196.27
5.0.10.0040.0206.25
5.0.00.0050.0326.23
4.4.90.0060.0204.78
4.4.80.0030.0154.76
4.4.70.0050.0204.75
4.4.60.0050.0134.75
4.4.50.0020.0214.77
4.4.40.0010.0304.71
4.4.30.0010.0174.76
4.4.20.0040.0144.84
4.4.10.0060.0204.85
4.4.00.0030.0294.76
4.3.110.0030.0154.67
4.3.100.0020.0214.66
4.3.90.0030.0184.64
4.3.80.0030.0254.58
4.3.70.0040.0204.63
4.3.60.0010.0164.63
4.3.50.0050.0174.62
4.3.40.0050.0234.54
4.3.30.0020.0213.29
4.3.20.0030.0153.26
4.3.10.0030.0153.22
4.3.00.0270.01713.57

preferences:
44.08 ms | 401 KiB | 5 Q