3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function calculate($n) { $result = 0; for ($i = 1; $i <= $n; $i++) { for($j = 1; $j <= $i; $j++) { $result += 1; } } return $result; } var_dump(calculate(30));
based on v86uY
Output for 4.3.0 - 7.2.0
int(465)