3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = "Skiing, ATV"; $b = "Skiin, ATV / 4x4"; $ts = []; $pieces = explode(',', $a); foreach ($pieces as $piece) { $exp = explode('/', $piece); foreach ($exp as $item) { $ts[] = $item; } } var_dump($ts);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 9, Position 2 = 22
Branch analysis from position: 9
2 jumps found. (Code = 78) Position 1 = 10, Position 2 = 22
Branch analysis from position: 10
2 jumps found. (Code = 77) Position 1 = 16, Position 2 = 20
Branch analysis from position: 16
2 jumps found. (Code = 78) Position 1 = 17, Position 2 = 20
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
Branch analysis from position: 20
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 20
Branch analysis from position: 22
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 22
filename:       /in/cOeVj
function name:  (null)
number of ops:  27
compiled vars:  !0 = $a, !1 = $b, !2 = $ts, !3 = $pieces, !4 = $piece, !5 = $exp, !6 = $item
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'Skiing%2C+ATV'
    3     1        ASSIGN                                                   !1, 'Skiin%2C+ATV+%2F+4x4'
    4     2        ASSIGN                                                   !2, <array>
    5     3        INIT_FCALL                                               'explode'
          4        SEND_VAL                                                 '%2C'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $10     
          7        ASSIGN                                                   !3, $10
    7     8      > FE_RESET_R                                       $12     !3, ->22
          9    > > FE_FETCH_R                                               $12, !4, ->22
    8    10    >   INIT_FCALL                                               'explode'
         11        SEND_VAL                                                 '%2F'
         12        SEND_VAR                                                 !4
         13        DO_ICALL                                         $13     
         14        ASSIGN                                                   !5, $13
    9    15      > FE_RESET_R                                       $15     !5, ->20
         16    > > FE_FETCH_R                                               $15, !6, ->20
   10    17    >   ASSIGN_DIM                                               !2
         18        OP_DATA                                                  !6
    9    19      > JMP                                                      ->16
         20    >   FE_FREE                                                  $15
    7    21      > JMP                                                      ->9
         22    >   FE_FREE                                                  $12
   14    23        INIT_FCALL                                               'var_dump'
         24        SEND_VAR                                                 !2
         25        DO_ICALL                                                 
         26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.86 ms | 1396 KiB | 17 Q