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 = 27
Branch analysis from position: 27
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 10
Branch analysis from position: 30
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 23
Branch analysis from position: 23
2 jumps found. (Code = 44) Position 1 = 26, Position 2 = 18
Branch analysis from position: 26
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 10
Branch analysis from position: 30
Branch analysis from position: 10
Branch analysis from position: 18
2 jumps found. (Code = 44) Position 1 = 26, Position 2 = 18
Branch analysis from position: 26
Branch analysis from position: 18
filename:       /in/Eg9Qm
function name:  (null)
number of ops:  34
compiled vars:  !0 = $txt, !1 = $firstSplit, !2 = $newArray, !3 = $i, !4 = $secondSplit, !5 = $j
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'explode'
          1        SEND_VAL                                                 '%21%21%21'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $6      
          4        ASSIGN                                           ~7      !1, $6
          5        CONCAT                                           ~8      '123%7E456%21%21%21789%7E012%21%21%21345%7E678%21%21%21901%7E234%21%21%21567%7E890%21%21%211234%7E5678', ~7
    2     6        ASSIGN                                                   !0, ~8
    4     7        ASSIGN                                                   !2, <array>
    7     8        ASSIGN                                                   !3, 0
          9      > JMP                                                      ->27
    8    10    >   INIT_FCALL                                               'explode'
         11        SEND_VAL                                                 '%7E'
         12        FETCH_DIM_R                                      ~12     !1, !3
         13        SEND_VAL                                                 ~12
         14        DO_ICALL                                         $13     
         15        ASSIGN                                                   !4, $13
    9    16        ASSIGN                                                   !5, 0
         17      > JMP                                                      ->23
   10    18    >   FETCH_DIM_R                                      ~18     !4, !5
         19        FETCH_DIM_W                                      $16     !2, !3
         20        ASSIGN_DIM                                               $16
         21        OP_DATA                                                  ~18
    9    22        PRE_INC                                                  !5
         23    >   COUNT                                            ~20     !4
         24        IS_SMALLER                                               !5, ~20
         25      > JMPNZ                                                    ~21, ->18
    7    26    >   PRE_INC                                                  !3
         27    >   COUNT                                            ~23     !1
         28        IS_SMALLER                                               !3, ~23
         29      > JMPNZ                                                    ~24, ->10
   13    30    >   INIT_FCALL                                               'print_r'
         31        SEND_VAR                                                 !2
         32        DO_ICALL                                                 
         33      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.34 ms | 1401 KiB | 17 Q