fork(2) download
  1. <?php
  2. $matches=array();
  3. $regExp="/(,\\S|жы|шы|координально|сдесь|(^|[^а-яА-Я])здел|[^,.]\\sа |[^.,]\\sно[\\.\\,]? )/ui";
  4. $text="Зделай-ка мне раздел сдесь координально";
  5. $count=preg_match_all($regExp, $text, $matches);
  6. echo "Найдено ошибок $count: \t";
  7. for($i=0; $i<=$count; ++$i)
  8. {
  9. echo $matches[0][$i];
  10. echo "\t";
  11. }
  12.  
  13.  
  14. // your code goes here
Success #stdin #stdout #stderr 0.01s 20568KB
stdin
Standard input is empty
stdout
Найдено ошибок 3: 	Здел	сдесь	координально		
stderr
PHP Notice:  Undefined offset: 3 in /home/mJJyhT/prog.php on line 10