3v4l.org

run code in 300+ PHP versions simultaneously
<?php $txt = "123~456!!!789~012!!!345~678!!!901~234!!!567~890!!!1234~5678"; $firstSplit = explode("!!!",$txt); $newArray = array(); for($i=0;$i<sizeof($firstSplit);$i++){ $secondSplit = explode("~",$firstSplit[$i]); for($j=0;$j<sizeof($secondSplit);$j++){ $newArray[$i][] = $secondSplit[$j]; } } print_r($newArray);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
2 jumps found. (Code = 44) Position 1 = 29, Position 2 = 9
Branch analysis from position: 29
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
2 jumps found. (Code = 44) Position 1 = 25, Position 2 = 17
Branch analysis from position: 25
2 jumps found. (Code = 44) Position 1 = 29, Position 2 = 9
Branch analysis from position: 29
Branch analysis from position: 9
Branch analysis from position: 17
2 jumps found. (Code = 44) Position 1 = 25, Position 2 = 17
Branch analysis from position: 25
Branch analysis from position: 17
filename:       /in/4AmsN
function name:  (null)
number of ops:  33
compiled vars:  !0 = $txt, !1 = $firstSplit, !2 = $newArray, !3 = $i, !4 = $secondSplit, !5 = $j
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '123%7E456%21%21%21789%7E012%21%21%21345%7E678%21%21%21901%7E234%21%21%21567%7E890%21%21%211234%7E5678'
    3     1        INIT_FCALL                                               'explode'
          2        SEND_VAL                                                 '%21%21%21'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $7      
          5        ASSIGN                                                   !1, $7
    4     6        ASSIGN                                                   !2, <array>
    7     7        ASSIGN                                                   !3, 0
          8      > JMP                                                      ->26
    8     9    >   INIT_FCALL                                               'explode'
         10        SEND_VAL                                                 '%7E'
         11        FETCH_DIM_R                                      ~11     !1, !3
         12        SEND_VAL                                                 ~11
         13        DO_ICALL                                         $12     
         14        ASSIGN                                                   !4, $12
    9    15        ASSIGN                                                   !5, 0
         16      > JMP                                                      ->22
   10    17    >   FETCH_DIM_R                                      ~17     !4, !5
         18        FETCH_DIM_W                                      $15     !2, !3
         19        ASSIGN_DIM                                               $15
         20        OP_DATA                                                  ~17
    9    21        PRE_INC                                                  !5
         22    >   COUNT                                            ~19     !4
         23        IS_SMALLER                                               !5, ~19
         24      > JMPNZ                                                    ~20, ->17
    7    25    >   PRE_INC                                                  !3
         26    >   COUNT                                            ~22     !1
         27        IS_SMALLER                                               !3, ~22
         28      > JMPNZ                                                    ~23, ->9
   13    29    >   INIT_FCALL                                               'print_r'
         30        SEND_VAR                                                 !2
         31        DO_ICALL                                                 
         32      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.63 ms | 1396 KiB | 17 Q