3v4l.org

run code in 300+ PHP versions simultaneously
<?php $hits = []; preg_match_all("/(?<=\s)\w/", " this is a string ", $hits, PREG_PATTERN_ORDER | PREG_OFFSET_CAPTURE); $result = array_column ( $hits[0], 1 ); $s_result = join ( ", ", $result); echo $s_result;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/OLlVG
function name:  (null)
number of ops:  20
compiled vars:  !0 = $hits, !1 = $result, !2 = $s_result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        INIT_FCALL                                               'preg_match_all'
          2        SEND_VAL                                                 '%2F%28%3F%3C%3D%5Cs%29%5Cw%2F'
          3        SEND_VAL                                                 '++this+++++is+++a+++string++'
          4        SEND_REF                                                 !0
          5        SEND_VAL                                                 257
          6        DO_ICALL                                                 
    5     7        INIT_FCALL                                               'array_column'
          8        FETCH_DIM_R                                      ~5      !0, 0
          9        SEND_VAL                                                 ~5
         10        SEND_VAL                                                 1
         11        DO_ICALL                                         $6      
         12        ASSIGN                                                   !1, $6
    6    13        INIT_FCALL                                               'join'
         14        SEND_VAL                                                 '%2C+'
         15        SEND_VAR                                                 !1
         16        DO_ICALL                                         $8      
         17        ASSIGN                                                   !2, $8
    7    18        ECHO                                                     !2
         19      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.12 ms | 1003 KiB | 16 Q