3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $samp = "This is an . example text using & my / Regex expression"; preg_match('/[^a-zA-Z_\s]/', "", $samp); $samp = str_replace(" "," ",$samp); $jk = explode(" ",$samp); $i = sizeof($jk); $j = 0; for($j=0;$j<$i-1;$j++) { echo $jk[$j]." ".$jk[$j+1]."\n"; }
Output for 5.3.1 - 7.1.0
Warning: explode() expects parameter 2 to be string, array given in /in/fL321 on line 5
Output for 4.3.0 - 5.3.0
Notice: Array to string conversion in /in/fL321 on line 5