Skip to content

Commit 5ac9644

Browse files
Create index2.php
1 parent 703b171 commit 5ac9644

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?php
2+
3+
$shifts = include("ids.php");
4+
5+
$ids = [];
6+
7+
$start = microtime(true);
8+
9+
foreach ($shifts as $shift) {
10+
if (strrpos($shift, '_') !== false) {
11+
$underscorePosition = strrpos($shift, '_');
12+
$substringOffset = $underscorePosition + 1;
13+
$ids[] = substr($shift, $substringOffset);
14+
} else {
15+
$ids[] = $shift;
16+
}
17+
}
18+
// var_dump($ids);
19+
20+
// echo microtime(true) - $start; 6.0081481933594E-5 microseconds

0 commit comments

Comments
 (0)