Check if value is in array
<?php
$values = $this->getRangeStrings($loop);
$uniques = array_slice($values, 0, count($values) / 2);
$this->start($loop);
foreach ($values as $value) {
$value = in_array($value, $uniques);
}
return $this->end();
PHP | Loops | Seconds | Percent |
---|---|---|---|
8.3.13 | 100.000 | 34.189533 | 100% |
8.3.10 | 100.000 | 29.665016 | 100% |
8.3.9 | 100.000 | 28.127331 | 100% |
7.3.33 | 100.000 | 23.354105 | 100% |
7.3.31 | 100.000 | 20.628238 | 100% |
7.3.30 | 100.000 | 20.516025 | 100% |
7.3.29 | 100.000 | 21.447551 | 100% |
7.3.28 | 100.000 | 22.214582 | 100% |
7.3.27 | 100.000 | 23.583363 | 100% |
7.3.24 | 100.000 | 23.709048 | 100% |
7.3.23 | 100.000 | 25.283351 | 100% |
7.3.22 | 100.000 | 23.381359 | 100% |
7.3.19 | 100.000 | 24.726413 | 100% |
7.3.18 | 100.000 | 21.979141 | 100% |
7.3.17 | 100.000 | 21.991631 | 100% |
7.3.16 | 100.000 | 22.184480 | 100% |
7.3.15 | 100.000 | 20.273933 | 100% |
7.3.14 | 100.000 | 21.771402 | 100% |
7.3.13 | 100.000 | 21.735091 | 100% |
7.3.12 | 100.000 | 19.426401 | 100% |
7.3.11 | 100.000 | 25.638335 | 100% |
7.3.9 | 100.000 | 28.664318 | 100% |
7.3.8 | 100.000 | 29.192158 | 100% |
7.2.29 | 100.000 | 27.329136 | 100% |
8.3.13 | 10.000 | 0.321191 | 100% |
7.2.34 | 100.000 | 31.319998 | 100% |
7.2.33 | 100.000 | 30.919828 | 100% |
7.2.31 | 100.000 | 29.936788 | 100% |
7.2.30 | 100.000 | 28.811716 | 100% |
8.3.10 | 10.000 | 0.278867 | 100% |
7.2.28 | 100.000 | 26.398034 | 100% |
7.2.27 | 100.000 | 28.194161 | 100% |
7.2.26 | 100.000 | 26.707198 | 100% |
7.2.25 | 100.000 | 25.230347 | 100% |
7.2.24 | 100.000 | 30.920320 | 100% |
7.2.22 | 100.000 | 35.557427 | 100% |
7.2.21 | 100.000 | 35.251430 | 100% |
7.1.33 | 100.000 | 29.523447 | 100% |
7.1.32 | 100.000 | 35.649243 | 100% |
7.1.31 | 100.000 | 35.232506 | 100% |
7.1.0 | 100.000 | 164.346441 | 100% |
7.0.33 | 100.000 | 29.998225 | 100% |
7.0.7 | 100.000 | 157.289755 | 100% |
5.6.40 | 100.000 | 164.820913 | +173% |
5.6.22 | 100.000 | 826.502073 | +168% |
5.5.36 | 100.000 | 784.241538 | +169% |
5.4.45 | 100.000 | 677.058957 | +165% |
5.3.29 | 100.000 | 649.156125 | +156% |
8.3.9 | 10.000 | 0.263326 | 100% |
8.0.30 | 100.000 | 26.378339 | 100% |
8.0.29 | 100.000 | 23.628499 | 100% |
8.0.28 | 100.000 | 23.062064 | 100% |
8.0.27 | 100.000 | 25.199871 | 100% |
8.0.26 | 100.000 | 26.360864 | 100% |
8.0.25 | 100.000 | 24.769227 | 100% |
8.0.24 | 100.000 | 24.090408 | 100% |
8.0.23 | 100.000 | 25.230617 | 100% |
8.0.20 | 10.000 | 0.236892 | 100% |
8.0.20 | 100.000 | 25.288953 | 100% |
8.0.19 | 10.000 | 0.205711 | 100% |
8.0.19 | 100.000 | 22.929285 | 100% |
8.0.17 | 10.000 | 0.194895 | 100% |
8.0.17 | 100.000 | 22.797278 | 100% |
8.0.16 | 10.000 | 0.196353 | 100% |
8.0.16 | 100.000 | 23.790157 | 100% |
8.0.14 | 10.000 | 0.166147 | 100% |
8.0.14 | 100.000 | 23.387461 | 100% |
8.0.11 | 100.000 | 22.775202 | 100% |
8.0.10 | 100.000 | 20.810629 | 100% |
8.0.9 | 100.000 | 22.374845 | 100% |
8.0.8 | 100.000 | 22.805134 | 100% |
8.0.7 | 100.000 | 22.370555 | 100% |
8.0.3 | 100.000 | 23.661168 | 100% |
8.0.2 | 100.000 | 25.643677 | 100% |
8.0.0 | 100.000 | 21.826767 | 100% |
7.4.33 | 100.000 | 24.126051 | 100% |
7.4.32 | 100.000 | 23.813142 | 100% |
7.4.30 | 100.000 | 26.698432 | 100% |
7.4.28 | 100.000 | 22.954676 | 100% |
7.4.27 | 100.000 | 24.491011 | 100% |
7.4.24 | 100.000 | 20.836332 | 100% |
7.4.23 | 100.000 | 20.831495 | 100% |
7.4.22 | 100.000 | 22.621179 | 100% |
8.0.11 | 10.000 | 0.206151 | 100% |
8.0.10 | 10.000 | 0.171957 | 100% |
8.0.0 | 10.000 | 0.169209 | 100% |
7.4.29 | 100.000 | 27.039681 | 100% |
7.4.21 | 10.000 | 0.177894 | 100% |
7.4.21 | 100.000 | 21.314574 | 100% |
7.4.20 | 10.000 | 0.170499 | 100% |
7.4.20 | 100.000 | 21.241360 | 100% |
7.4.16 | 100.000 | 23.428705 | 100% |
7.4.15 | 100.000 | 26.083479 | 100% |
7.4.33 | 10.000 | 0.204269 | 100% |
7.4.32 | 10.000 | 0.223447 | 100% |
7.4.30 | 10.000 | 0.252866 | 100% |
7.4.29 | 10.000 | 0.261939 | 100% |
7.4.24 | 10.000 | 0.161585 | 100% |
7.4.23 | 10.000 | 0.162961 | 100% |
7.4.22 | 10.000 | 0.193798 | 100% |
7.4.13 | 100.000 | 22.551958 | 100% |
7.4.12 | 100.000 | 25.293444 | 100% |
7.4.11 | 100.000 | 25.178772 | 100% |
7.4.10 | 100.000 | 24.264215 | 100% |
8.0.2 | 10.000 | 0.275159 | 100% |
7.4.0 | 100.000 | 27.153950 | 100% |
8.0.30 | 10.000 | 0.244081 | 100% |
8.0.29 | 10.000 | 0.215435 | 100% |
8.0.28 | 10.000 | 0.197968 | 100% |
8.0.27 | 10.000 | 0.215884 | 100% |
8.0.26 | 10.000 | 0.224432 | 100% |
8.0.25 | 10.000 | 0.223557 | 100% |
8.0.24 | 10.000 | 0.237161 | 100% |
8.0.23 | 10.000 | 0.263962 | 100% |
8.0.9 | 10.000 | 0.188855 | 100% |
8.0.8 | 10.000 | 0.193003 | 100% |
8.0.7 | 10.000 | 0.194573 | 100% |
8.0.3 | 10.000 | 0.231611 | 100% |
7.4.28 | 10.000 | 0.191971 | 100% |
7.4.27 | 10.000 | 0.208319 | 100% |
7.4.16 | 10.000 | 0.226414 | 100% |
7.4.15 | 10.000 | 0.250905 | 100% |
7.4.13 | 10.000 | 0.183941 | 100% |
7.4.12 | 10.000 | 0.171155 | 100% |
7.4.11 | 10.000 | 0.205484 | 100% |
7.4.10 | 10.000 | 0.191715 | 100% |
7.4.7 | 10.000 | 0.172902 | 100% |
7.4.7 | 100.000 | 23.619680 | 100% |
7.4.6 | 10.000 | 0.196472 | 100% |
7.4.6 | 100.000 | 22.051722 | 100% |
7.4.5 | 10.000 | 0.201432 | 100% |
7.4.5 | 100.000 | 22.759307 | 100% |
7.4.4 | 10.000 | 0.191706 | 100% |
7.4.4 | 100.000 | 22.056114 | 100% |
7.4.3 | 10.000 | 0.198843 | 100% |
7.4.3 | 100.000 | 21.948501 | 100% |
7.4.1 | 100.000 | 20.784202 | 100% |
7.4.2 | 10.000 | 0.203463 | 100% |
7.4.2 | 100.000 | 23.147920 | 100% |
7.4.1 | 10.000 | 0.171527 | 100% |
7.4.0 | 10.000 | 0.230563 | 100% |
7.3.33 | 10.000 | 0.203470 | 100% |
7.3.31 | 10.000 | 0.175799 | 100% |
7.3.30 | 10.000 | 0.166575 | 100% |
7.3.29 | 10.000 | 0.170315 | 100% |
7.3.28 | 10.000 | 0.191340 | 100% |
7.3.27 | 10.000 | 0.218613 | 100% |
7.3.24 | 10.000 | 0.197642 | 100% |
7.3.23 | 10.000 | 0.201775 | 100% |
7.3.22 | 10.000 | 0.163170 | 100% |
7.3.19 | 10.000 | 0.208303 | 100% |
7.3.18 | 10.000 | 0.199889 | 100% |
7.3.17 | 10.000 | 0.179908 | 100% |
7.3.16 | 10.000 | 0.192409 | 100% |
7.3.15 | 10.000 | 0.156191 | 100% |
7.3.14 | 10.000 | 0.175637 | 100% |
7.3.13 | 10.000 | 0.190479 | 100% |
7.3.12 | 10.000 | 0.155731 | 100% |
7.3.11 | 10.000 | 0.213188 | 100% |
7.3.9 | 10.000 | 0.229516 | 100% |
7.3.8 | 10.000 | 0.243316 | 100% |
7.2.34 | 10.000 | 0.238159 | 100% |
7.2.33 | 10.000 | 0.230290 | 100% |
7.2.31 | 10.000 | 0.227195 | 100% |
7.2.30 | 10.000 | 0.222587 | 100% |
7.2.29 | 10.000 | 0.215047 | 100% |
7.2.28 | 10.000 | 0.205959 | 100% |
7.2.27 | 10.000 | 0.217346 | 100% |
7.2.26 | 10.000 | 0.205440 | 100% |
7.2.25 | 10.000 | 0.185977 | 100% |
7.2.24 | 10.000 | 0.236928 | 100% |
7.2.22 | 10.000 | 0.299533 | 100% |
7.2.21 | 10.000 | 0.303078 | 100% |
7.1.33 | 10.000 | 0.233297 | 100% |
7.1.32 | 10.000 | 0.330866 | 100% |
7.1.31 | 10.000 | 0.300011 | 100% |
7.1.0 | 10.000 | 1.190495 | 100% |
7.0.33 | 10.000 | 0.237316 | 100% |
7.0.7 | 10.000 | 1.133790 | 100% |
5.6.40 | 10.000 | 1.284515 | +186% |
5.6.22 | 10.000 | 5.384011 | +190% |
5.5.36 | 10.000 | 5.170986 | +188% |
5.4.45 | 10.000 | 4.341305 | +193% |
5.3.29 | 10.000 | 3.995058 | +184% |
Check if value is in array (strict)
<?php
$values = $this->getRangeStrings($loop);
$uniques = array_slice($values, 0, count($values) / 2);
$this->start($loop);
foreach ($values as $value) {
$value = in_array($value, $uniques, true);
}
return $this->end();
PHP | Loops | Seconds | Percent |
---|---|---|---|
8.3.13 | 100.000 | 72.163440 | +211% |
8.3.10 | 100.000 | 49.975925 | +168% |
8.3.9 | 100.000 | 47.048797 | +167% |
7.3.33 | 100.000 | 37.043999 | +159% |
7.3.31 | 100.000 | 31.557061 | +153% |
7.3.30 | 100.000 | 31.194325 | +152% |
7.3.29 | 100.000 | 31.832539 | +148% |
7.3.28 | 100.000 | 30.590434 | +138% |
7.3.27 | 100.000 | 34.049125 | +144% |
7.3.24 | 100.000 | 34.348750 | +145% |
7.3.23 | 100.000 | 36.197607 | +143% |
7.3.22 | 100.000 | 33.753063 | +144% |
7.3.19 | 100.000 | 35.169761 | +142% |
7.3.18 | 100.000 | 30.746767 | +140% |
7.3.17 | 100.000 | 31.221073 | +142% |
7.3.16 | 100.000 | 31.540457 | +142% |
7.3.15 | 100.000 | 29.128390 | +144% |
7.3.14 | 100.000 | 32.589069 | +150% |
7.3.13 | 100.000 | 31.133286 | +143% |
7.3.12 | 100.000 | 28.464340 | +147% |
7.3.11 | 100.000 | 39.388113 | +154% |
7.3.9 | 100.000 | 43.945657 | +153% |
7.3.8 | 100.000 | 45.757963 | +157% |
7.2.29 | 100.000 | 38.359572 | +140% |
8.3.13 | 10.000 | 0.760233 | +237% |
7.2.34 | 100.000 | 43.894435 | +140% |
7.2.33 | 100.000 | 45.855550 | +148% |
7.2.31 | 100.000 | 43.164039 | +144% |
7.2.30 | 100.000 | 41.441471 | +144% |
8.3.10 | 10.000 | 0.503401 | +181% |
7.2.28 | 100.000 | 37.479473 | +142% |
7.2.27 | 100.000 | 39.989482 | +142% |
7.2.26 | 100.000 | 38.742796 | +145% |
7.2.25 | 100.000 | 34.839239 | +138% |
7.2.24 | 100.000 | 45.722975 | +148% |
7.2.22 | 100.000 | 52.498528 | +148% |
7.2.21 | 100.000 | 52.332941 | +148% |
7.1.33 | 100.000 | 41.463560 | +140% |
7.1.32 | 100.000 | 53.406290 | +150% |
7.1.31 | 100.000 | 52.431222 | +149% |
7.1.0 | 100.000 | 308.330061 | +188% |
7.0.33 | 100.000 | 41.911500 | +140% |
7.0.7 | 100.000 | 295.674032 | +188% |
5.6.40 | 100.000 | 95.244354 | 100% |
5.6.22 | 100.000 | 491.216068 | 100% |
5.5.36 | 100.000 | 463.622809 | 100% |
5.4.45 | 100.000 | 410.222035 | 100% |
5.3.29 | 100.000 | 415.205876 | 100% |
8.3.9 | 10.000 | 0.453607 | +172% |
8.0.30 | 100.000 | 39.114210 | +148% |
8.0.29 | 100.000 | 32.862812 | +139% |
8.0.28 | 100.000 | 30.703892 | +133% |
8.0.27 | 100.000 | 31.404394 | +125% |
8.0.26 | 100.000 | 33.008888 | +125% |
8.0.25 | 100.000 | 31.970116 | +129% |
8.0.24 | 100.000 | 30.152651 | +125% |
8.0.23 | 100.000 | 32.391979 | +128% |
8.0.20 | 10.000 | 0.304571 | +129% |
8.0.20 | 100.000 | 32.059405 | +127% |
8.0.19 | 10.000 | 0.238063 | +116% |
8.0.19 | 100.000 | 28.606103 | +125% |
8.0.17 | 10.000 | 0.273711 | +140% |
8.0.17 | 100.000 | 31.499805 | +138% |
8.0.16 | 10.000 | 0.315611 | +161% |
8.0.16 | 100.000 | 36.045799 | +152% |
8.0.14 | 10.000 | 0.261545 | +157% |
8.0.14 | 100.000 | 33.685618 | +144% |
8.0.11 | 100.000 | 32.844164 | +144% |
8.0.10 | 100.000 | 31.195323 | +150% |
8.0.9 | 100.000 | 33.102232 | +148% |
8.0.8 | 100.000 | 31.955807 | +140% |
8.0.7 | 100.000 | 32.403171 | +145% |
8.0.3 | 100.000 | 33.278354 | +141% |
8.0.2 | 100.000 | 38.556823 | +150% |
8.0.0 | 100.000 | 32.367867 | +148% |
7.4.33 | 100.000 | 39.898027 | +165% |
7.4.32 | 100.000 | 33.061421 | +139% |
7.4.30 | 100.000 | 33.074704 | +124% |
7.4.28 | 100.000 | 33.375164 | +145% |
7.4.27 | 100.000 | 35.431849 | +145% |
7.4.24 | 100.000 | 33.161620 | +159% |
7.4.23 | 100.000 | 32.078447 | +154% |
7.4.22 | 100.000 | 32.027855 | +142% |
8.0.11 | 10.000 | 0.310679 | +151% |
8.0.10 | 10.000 | 0.280426 | +163% |
8.0.0 | 10.000 | 0.271345 | +160% |
7.4.29 | 100.000 | 33.040574 | +122% |
7.4.21 | 10.000 | 0.294979 | +166% |
7.4.21 | 100.000 | 32.960243 | +155% |
7.4.20 | 10.000 | 0.270979 | +159% |
7.4.20 | 100.000 | 31.087776 | +146% |
7.4.16 | 100.000 | 33.610204 | +143% |
7.4.15 | 100.000 | 38.614952 | +148% |
7.4.33 | 10.000 | 0.386782 | +189% |
7.4.32 | 10.000 | 0.307641 | +138% |
7.4.30 | 10.000 | 0.305131 | +121% |
7.4.29 | 10.000 | 0.313206 | +120% |
7.4.24 | 10.000 | 0.326498 | +202% |
7.4.23 | 10.000 | 0.296468 | +182% |
7.4.22 | 10.000 | 0.271183 | +140% |
7.4.13 | 100.000 | 34.174054 | +152% |
7.4.12 | 100.000 | 40.359230 | +160% |
7.4.11 | 100.000 | 36.411692 | +145% |
7.4.10 | 100.000 | 35.534413 | +146% |
8.0.2 | 10.000 | 0.451519 | +164% |
7.4.0 | 100.000 | 41.137803 | +151% |
8.0.30 | 10.000 | 0.375716 | +154% |
8.0.29 | 10.000 | 0.311380 | +145% |
8.0.28 | 10.000 | 0.275648 | +139% |
8.0.27 | 10.000 | 0.249070 | +115% |
8.0.26 | 10.000 | 0.265657 | +118% |
8.0.25 | 10.000 | 0.294178 | +132% |
8.0.24 | 10.000 | 0.283204 | +119% |
8.0.23 | 10.000 | 0.294447 | +112% |
8.0.9 | 10.000 | 0.308147 | +163% |
8.0.8 | 10.000 | 0.307901 | +160% |
8.0.7 | 10.000 | 0.296574 | +152% |
8.0.3 | 10.000 | 0.326065 | +141% |
7.4.28 | 10.000 | 0.304937 | +159% |
7.4.27 | 10.000 | 0.315561 | +151% |
7.4.16 | 10.000 | 0.323946 | +143% |
7.4.15 | 10.000 | 0.450216 | +179% |
7.4.13 | 10.000 | 0.312735 | +170% |
7.4.12 | 10.000 | 0.340299 | +199% |
7.4.11 | 10.000 | 0.311635 | +152% |
7.4.10 | 10.000 | 0.301810 | +157% |
7.4.7 | 10.000 | 0.324124 | +187% |
7.4.7 | 100.000 | 37.069535 | +157% |
7.4.6 | 10.000 | 0.283419 | +144% |
7.4.6 | 100.000 | 31.702014 | +144% |
7.4.5 | 10.000 | 0.292213 | +145% |
7.4.5 | 100.000 | 31.914105 | +140% |
7.4.4 | 10.000 | 0.274781 | +143% |
7.4.4 | 100.000 | 30.939698 | +140% |
7.4.3 | 10.000 | 0.264999 | +133% |
7.4.3 | 100.000 | 30.383539 | +138% |
7.4.1 | 100.000 | 31.177092 | +150% |
7.4.2 | 10.000 | 0.297104 | +146% |
7.4.2 | 100.000 | 32.911507 | +142% |
7.4.1 | 10.000 | 0.281327 | +164% |
7.4.0 | 10.000 | 0.482961 | +209% |
7.3.33 | 10.000 | 0.348683 | +171% |
7.3.31 | 10.000 | 0.272552 | +155% |
7.3.30 | 10.000 | 0.291827 | +175% |
7.3.29 | 10.000 | 0.273876 | +161% |
7.3.28 | 10.000 | 0.243850 | +127% |
7.3.27 | 10.000 | 0.337009 | +154% |
7.3.24 | 10.000 | 0.279058 | +141% |
7.3.23 | 10.000 | 0.328993 | +163% |
7.3.22 | 10.000 | 0.267203 | +164% |
7.3.19 | 10.000 | 0.291703 | +140% |
7.3.18 | 10.000 | 0.263071 | +132% |
7.3.17 | 10.000 | 0.258666 | +144% |
7.3.16 | 10.000 | 0.273847 | +142% |
7.3.15 | 10.000 | 0.227821 | +146% |
7.3.14 | 10.000 | 0.282767 | +161% |
7.3.13 | 10.000 | 0.273601 | +144% |
7.3.12 | 10.000 | 0.228976 | +147% |
7.3.11 | 10.000 | 0.433445 | +203% |
7.3.9 | 10.000 | 0.581817 | +253% |
7.3.8 | 10.000 | 0.540692 | +222% |
7.2.34 | 10.000 | 0.378951 | +159% |
7.2.33 | 10.000 | 0.390744 | +170% |
7.2.31 | 10.000 | 0.362253 | +159% |
7.2.30 | 10.000 | 0.321936 | +145% |
7.2.29 | 10.000 | 0.318075 | +148% |
7.2.28 | 10.000 | 0.314737 | +153% |
7.2.27 | 10.000 | 0.326106 | +150% |
7.2.26 | 10.000 | 0.326466 | +159% |
7.2.25 | 10.000 | 0.285195 | +153% |
7.2.24 | 10.000 | 0.483656 | +204% |
7.2.22 | 10.000 | 0.673348 | +225% |
7.2.21 | 10.000 | 0.616069 | +203% |
7.1.33 | 10.000 | 0.365228 | +157% |
7.1.32 | 10.000 | 0.668013 | +202% |
7.1.31 | 10.000 | 0.614599 | +205% |
7.1.0 | 10.000 | 2.513920 | +211% |
7.0.33 | 10.000 | 0.368472 | +155% |
7.0.7 | 10.000 | 2.412636 | +213% |
5.6.40 | 10.000 | 0.691593 | 100% |
5.6.22 | 10.000 | 2.830476 | 100% |
5.5.36 | 10.000 | 2.744386 | 100% |
5.4.45 | 10.000 | 2.251853 | 100% |
5.3.29 | 10.000 | 2.167766 | 100% |