3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = '{},\"employees\":{},\"idIwant\":{\"2545\":{\"attributes\":{\"offset\":9855,'; echo preg_match('~"idIwant\\\":{\\\"\K\d+~', $string, $out) ? $out[0] : 'bonk';

preferences:
28.99 ms | 404 KiB | 5 Q