3v4l.org

run code in 500+ PHP versions simultaneously
<?php $string = "hello world. Hello world"; $words = explode(' ', $string); $html = '<span>' . $words[0] . '</span> ' . Implode(" ", array_slice($words,1)); Echo $html;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/oTORH
function name:  (null)
number of ops:  18
compiled vars:  !0 = $string, !1 = $words, !2 = $html
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                       !0, 'hello+world.+Hello+world'
    3     1        INIT_FCALL                                                   'explode'
          2        SEND_VAL                                                     '+'
          3        SEND_VAR                                                     !0
          4        DO_ICALL                                             $4      
          5        ASSIGN                                                       !1, $4
    5     6        FETCH_DIM_R                                          ~6      !1, 0
          7        CONCAT                                               ~7      '%3Cspan%3E', ~6
          8        CONCAT                                               ~8      ~7, '%3C%2Fspan%3E+'
          9        INIT_FCALL                                                   'array_slice'
         10        SEND_VAR                                                     !1
         11        SEND_VAL                                                     1
         12        DO_ICALL                                             $9      
         13        FRAMELESS_ICALL_2                implode             ~10     '+', $9
         14        CONCAT                                               ~11     ~8, ~10
         15        ASSIGN                                                       !2, ~11
    7    16        ECHO                                                         !2
    8    17      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
176.97 ms | 2584 KiB | 15 Q