3v4l.org

run code in 300+ PHP versions simultaneously
<?php $author = 'Shevchuk T.I., Piskun R.P., Vasenko T.B.'; $str_arr1= explode(", ", $author); foreach($str_arr1 as $str_arr) { $initials= preg_split('/([A-Z]\.[A-Z]\.|[A-Z]\.\s+[A-Z]\.|[A-Z][a-z]\.)/', $str_arr, -1, PREG_SPLIT_NO_EMPTY); $surnames= preg_split('/\w{3,15}/', $str_arr, -1, PREG_SPLIT_NO_EMPTY); print_r($initials); print_r($surnames); }
Output for git.master, git.master_jit, rfc.property-hooks
Array ( [0] => Shevchuk ) Array ( [0] => T.I. ) Array ( [0] => Piskun ) Array ( [0] => R.P. ) Array ( [0] => Vasenko ) Array ( [0] => T.B. )

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
159.22 ms | 405 KiB | 5 Q