3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $word = "Capuaalo"; $length = count($word); $count = 0; for($i = 0; $i < $length; $i++) { if($search = substr($word, $i, 1)=="a"){ $count = $count + 1; } } echo $length; echo substr($word, 0, 1); echo $count; ?>
Output for 4.3.0 - 7.1.0
1C0