3v4l.org

run code in 300+ PHP versions simultaneously
<?php $dir = "../AttachFile/"; $query = mssql_query("select [gc_parent_guid] FROM [dbo].[MailAttachment] INNER JOIN [dbo].[Status] ON [MailAttachment].[gc_parent_guid] = [Status].[Mail_ID] Where [Status].[Entry No] = $view_no "); $row = mssql_fetch_array($query); $gc_parent_guid = mssql_guid_string($row['gc_parent_guid']); //echo $gc_parent_guid; // Open a directory, and read its contents if (is_dir($dir)){ // ตรวจสอบว่าเป็นDirectoryหรือไม่ if ($dh = opendir($dir)){ $i = 0; //แสดงไฟล์ทั้งหมดในโฟลเดอร์ while (($file[] = readdir($dh)) !== false){ //String ทั้งหมด ที่ต้องการค้นหา $mixedStr = $file[$i]; //คำที่จะค้นหา $searchStr = $gc_parent_guid; //แทนที่ ช่องว่างโดย %20 MOD REWRITE $LinkFile = str_replace(" ", "%20", $mixedStr); if (strpos($mixedStr, $searchStr) !== false){ // echo "<br/>"."- "."<a href= ".$dir.$LinkFile.">".$file[$i]."</a><br>"; } $i++ ; } closedir($dh); } } ?>

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.0070.00718.92
8.3.30.0100.01018.79
8.3.20.0050.00220.16
8.3.10.0050.00323.57
8.3.00.0000.00823.61
8.2.170.0140.00322.96
8.2.160.0070.00720.39
8.2.150.0040.00424.18
8.2.140.0030.00624.66
8.2.130.0080.00019.63
8.2.120.0030.00626.35
8.2.110.0030.00722.20
8.2.100.0040.00717.90
8.2.90.0090.00019.09
8.2.80.0000.00817.97
8.2.70.0040.00417.63
8.2.60.0050.00317.80
8.2.50.0000.00818.07
8.2.40.0000.00822.25
8.2.30.0060.00319.39
8.2.20.0000.00717.58
8.2.10.0000.00818.04
8.2.00.0040.00418.11
8.1.270.0060.00322.18
8.1.260.0050.00328.09
8.1.250.0040.00428.09
8.1.240.0030.00622.26
8.1.230.0060.00719.12
8.1.220.0030.00517.74
8.1.210.0000.00818.77
8.1.200.0030.00717.36
8.1.190.0040.00417.35
8.1.180.0040.00418.10
8.1.170.0040.00418.52
8.1.160.0000.00820.70
8.1.150.0040.00418.81
8.1.140.0050.00319.50
8.1.130.0000.00817.54
8.1.120.0070.00017.36
8.1.110.0070.00017.32
8.1.100.0050.00217.38
8.1.90.0050.00317.39
8.1.80.0040.00417.46
8.1.70.0030.00317.41
8.1.60.0030.00517.39
8.1.50.0000.00817.40
8.1.40.0040.00417.50
8.1.30.0000.00817.66
8.1.20.0040.00417.55
8.1.10.0040.00417.46
8.1.00.0030.00617.42
8.0.300.0070.00018.77
8.0.290.0000.00716.63
8.0.280.0000.00818.39
8.0.270.0050.00217.14
8.0.260.0000.00717.10
8.0.250.0030.00316.87
8.0.240.0030.00616.87
8.0.230.0040.00416.99
8.0.220.0040.00416.91
8.0.210.0070.00016.90
8.0.200.0030.00316.84
8.0.190.0040.00416.95
8.0.180.0000.00716.93
8.0.170.0030.00516.91
8.0.160.0040.00416.79
8.0.150.0070.00016.73
8.0.140.0000.00716.71
8.0.130.0000.00713.33
8.0.120.0100.00114.45
8.0.110.0080.00314.47
8.0.100.0080.00314.49
8.0.90.0040.00714.49
8.0.80.0090.00414.53
8.0.70.0070.00414.48
8.0.60.0060.00414.52
8.0.50.0100.00114.42
8.0.30.0080.00715.09
8.0.20.0090.00715.77
8.0.10.0080.00214.59
8.0.00.0050.00915.36
7.4.330.0000.00615.08
7.4.320.0000.00616.54
7.4.300.0070.00016.64
7.4.290.0070.00016.46
7.4.280.0040.00416.59
7.4.270.0050.00216.60
7.4.260.0060.00316.58
7.4.250.0080.00414.31
7.4.240.0070.00414.89
7.4.230.0090.00314.39
7.4.220.0090.00514.38
7.4.210.0100.00515.25
7.4.200.0040.00714.33
7.4.190.0110.00113.35
7.4.180.0080.00413.28
7.4.160.0120.00214.40
7.4.150.0030.01114.61
7.4.140.0110.00415.52
7.4.130.0060.00614.34
7.4.120.0110.00414.88
7.4.110.0110.00314.28
7.4.100.0110.00314.32
7.4.90.0100.00614.35
7.4.80.0100.00515.25
7.4.70.0060.00814.25
7.4.60.0080.00814.35
7.4.50.0080.00414.30
7.4.40.0080.00614.26
7.4.30.0090.00614.33
7.4.20.0090.00313.24
7.4.10.0050.00713.83
7.4.00.0060.00814.08
7.3.330.0050.00013.15
7.3.320.0110.00213.12
7.3.310.0080.00314.18
7.3.300.0080.00214.01
7.3.290.0080.00314.15
7.3.280.0080.00715.04
7.3.270.0130.00214.54
7.3.260.0110.00614.15
7.3.250.0140.00012.99
7.3.240.0100.00614.76
7.3.230.0060.00814.17
7.3.220.0070.00613.02
7.3.210.0130.00214.12
7.3.200.0070.00815.10
7.3.190.0060.00914.13
7.3.180.0060.00714.21
7.3.170.0080.00514.11
7.3.160.0100.00214.10
7.3.150.0100.00212.99
7.3.140.0090.00113.03
7.3.130.0080.00513.69
7.3.120.0070.00813.47
7.3.110.0060.00713.50
7.3.100.0070.00613.48
7.3.90.0070.00513.73
7.3.80.0100.00213.63
7.3.70.0010.00913.68
7.3.60.0080.00413.73
7.3.50.0050.00613.62
7.3.40.0070.00513.60
7.3.30.0060.00613.70
7.3.20.0070.00515.44
7.3.10.0050.00615.30
7.3.00.0090.00315.37
7.2.340.0090.00412.96
7.2.330.0090.00714.15
7.2.320.0090.00714.12
7.2.310.0100.00514.16
7.2.300.0130.00914.12
7.2.290.0110.00414.18
7.2.280.0080.00513.08
7.2.270.0100.00313.02
7.2.260.0100.00513.59
7.2.250.0090.00513.49
7.2.240.0040.00913.77
7.2.230.0070.00813.70
7.2.220.0050.00813.65
7.2.210.0080.00613.59
7.2.200.0080.00613.70
7.2.190.0040.00913.70
7.2.180.0070.00513.67
7.2.170.0070.00613.80
7.2.160.0030.00913.73
7.2.150.0080.00615.67
7.2.140.0060.00715.69
7.2.130.0100.00415.65
7.2.120.0060.00715.57
7.2.110.0080.00515.59
7.2.100.0070.00715.69
7.2.90.0090.00515.62
7.2.80.0080.00615.60
7.2.70.0070.00915.62
7.2.60.0100.00615.84
7.2.50.0090.00515.69
7.2.40.0090.00515.70
7.2.30.0050.00715.56
7.2.20.0110.00215.56
7.2.10.0080.00615.69
7.2.00.0060.00716.46
7.1.330.0040.00914.61
7.1.320.0090.00614.52
7.1.310.0070.00614.61
7.1.300.0080.00514.44
7.1.290.0090.00314.53
7.1.280.0060.00714.61
7.1.270.0050.00714.51
7.1.260.0100.00214.49
7.1.250.0090.00514.45
7.1.240.0100.00214.44
7.1.230.0050.00814.59
7.1.220.0090.00514.54
7.1.210.0090.00414.61
7.1.200.0080.00414.72
7.1.190.0090.00314.54
7.1.180.0090.00314.43
7.1.170.0100.00314.50
7.1.160.0050.00714.47
7.1.150.0100.00214.53
7.1.140.0080.00414.54
7.1.130.0100.00214.57
7.1.120.0090.00214.43
7.1.110.0080.00314.58
7.1.100.0090.00415.34
7.1.90.0080.00614.46
7.1.80.0040.00714.67
7.1.70.0080.00415.12
7.1.60.0100.00615.79
7.1.50.0060.00815.09
7.1.40.0090.00414.50
7.1.30.0060.00714.58
7.1.20.0080.00414.52
7.1.10.0070.00514.48
7.1.00.0070.02316.46
7.0.330.0110.00114.36
7.0.320.0080.00514.32
7.0.310.0080.00514.42
7.0.300.0070.00614.27
7.0.290.0060.00714.44
7.0.280.0090.00314.45
7.0.270.0080.00514.37
7.0.260.0090.00314.38
7.0.250.0070.00414.49
7.0.240.0060.00614.45
7.0.230.0070.00614.40
7.0.220.0120.00114.49
7.0.210.0080.00414.44
7.0.200.0070.00315.00
7.0.190.0070.00414.42
7.0.180.0090.00414.37
7.0.170.0060.00714.37
7.0.160.0090.00214.28
7.0.150.0100.00114.41
7.0.140.0040.00714.40
7.0.130.0060.00614.40
7.0.120.0090.00314.40
7.0.110.0080.00414.36
7.0.100.0130.01315.78
7.0.90.0110.02715.84
7.0.80.0110.02615.73
7.0.70.0150.02415.71
7.0.60.0060.02515.78
7.0.50.0100.02015.84
7.0.40.0060.02215.34
7.0.30.0070.02315.38
7.0.20.0100.02115.35
7.0.10.0090.02315.28
7.0.00.0060.01715.37
5.6.400.0090.00213.08
5.6.390.0090.00413.21
5.6.380.0060.00713.04
5.6.370.0070.00612.93
5.6.360.0060.00613.02
5.6.350.0070.00612.99
5.6.340.0060.00513.01
5.6.330.0050.00713.01
5.6.320.0060.00613.11
5.6.310.0100.00313.03
5.6.300.0100.00212.98
5.6.290.0080.00313.12
5.6.280.0080.01015.21
5.6.270.0090.00312.92
5.6.260.0070.00412.98
5.6.250.0090.01414.80
5.6.240.0100.01314.94
5.6.230.0080.02415.02
5.6.220.0040.02714.97
5.6.210.0060.02314.98
5.6.200.0070.02215.12
5.6.190.0090.01115.12
5.6.180.0080.02414.98
5.6.170.0070.02314.99
5.6.160.0050.02515.08
5.6.150.0070.02015.16
5.6.140.0060.01715.02
5.6.130.0060.01615.05
5.6.120.0090.01815.06
5.6.110.0060.02515.00
5.6.100.0080.01814.99
5.6.90.0130.01915.11
5.6.80.0070.02314.89
5.6.70.0070.02314.88
5.6.60.0080.01914.95
5.6.50.0080.02514.93
5.6.40.0050.02114.79
5.6.30.0090.02314.85
5.6.20.0080.01714.78
5.6.10.0070.02114.85
5.6.00.0080.02114.85
5.5.380.0070.03115.07
5.5.370.0080.01615.14
5.5.360.0070.02814.95
5.5.350.0120.01714.98
5.5.340.0130.02515.14
5.5.330.0070.02815.06
5.5.320.0090.02915.14
5.5.310.0080.03115.29
5.5.300.0080.02615.19
5.5.290.0070.01915.24
5.5.280.0100.02215.10
5.5.270.0050.02515.14
5.5.260.0080.02915.08
5.5.250.0090.02915.27
5.5.240.0040.02115.05
5.5.230.0090.01815.05
5.5.220.0080.02815.13
5.5.210.0030.02415.11
5.5.200.0100.02815.04
5.5.190.0090.03014.91
5.5.180.0070.03014.92
5.5.170.0090.00312.33
5.5.160.0090.02714.89
5.5.150.0090.01814.87
5.5.140.0090.02514.91
5.5.130.0050.03014.82
5.5.120.0090.02714.91
5.5.110.0110.02314.88
5.5.100.0060.03114.94
5.5.90.0080.02715.02
5.5.80.0090.01614.88
5.5.70.0070.03214.94
5.5.60.0090.02715.00
5.5.50.0090.02214.95
5.5.40.0070.02815.01
5.5.30.0120.01415.07
5.5.20.0090.02814.88
5.5.10.0090.02814.88
5.5.00.0100.02314.86

preferences:
47.04 ms | 400 KiB | 5 Q