3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $t = array(1, 2, 5, 6, 9, 3, 6, 32, 54, 123, 765, 234, 754, 234, 321, 43564, 467, 4523, 7645, 345, 234, 764, 24236, 3564562, 365362, 13536, 6743, 74567, 7464564, 467476, 245); $n = count($t); $s = 0; for ($i = 0; $i < $n; $i++) { $s += round($t[$i] * 2 / 3); } echo $s;
Output for 4.3.0 - 7.1.0
8027587