3v4l.org

run code in 300+ PHP versions simultaneously
<?php $re = '/(?:\|\h*|\G(?!^))([^.\r\n]+)\.\h*/'; $str = '| This is one. This is two. John loves Mary.| This is one. This is two.'; preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0); print_r($matches);

This is an error 500

Value for `_results` contains invalid data `array`


preferences:
151.26 ms | 2172 KiB | 10 Q