3v4l.org

run code in 300+ PHP versions simultaneously
<?php //$Input = [0,{"a":1,"b":2,"c":3,"d":[4,5]},[6,[7,8]],9,10]; <- isnt valid PHP. $Input = '[0,{"a":1,"b":2,"c":3,"d":[4,5]},[6,[7,8]],9,10]'; $myArray = explode(',', $Input ); //print_r($myArray); //$length = strlen($Input); foreach($myArray as $my_Array){ echo $my_Array.'<br>'; } $Output = '[1,{"a":2,"b":3,"c":4,"d":[5,6]},[7,[8,9]],10,11]'; ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 7, Position 2 = 11
Branch analysis from position: 7
2 jumps found. (Code = 78) Position 1 = 8, Position 2 = 11
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
filename:       /in/60a33
function name:  (null)
number of ops:  14
compiled vars:  !0 = $Input, !1 = $myArray, !2 = $my_Array, !3 = $Output
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, '%5B0%2C%7B%22a%22%3A1%2C%22b%22%3A2%2C%22c%22%3A3%2C%22d%22%3A%5B4%2C5%5D%7D%2C%5B6%2C%5B7%2C8%5D%5D%2C9%2C10%5D'
    5     1        INIT_FCALL                                               'explode'
          2        SEND_VAL                                                 '%2C'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $5      
          5        ASSIGN                                                   !1, $5
   10     6      > FE_RESET_R                                       $7      !1, ->11
          7    > > FE_FETCH_R                                               $7, !2, ->11
   11     8    >   CONCAT                                           ~8      !2, '%3Cbr%3E'
          9        ECHO                                                     ~8
   10    10      > JMP                                                      ->7
         11    >   FE_FREE                                                  $7
   16    12        ASSIGN                                                   !3, '%5B1%2C%7B%22a%22%3A2%2C%22b%22%3A3%2C%22c%22%3A4%2C%22d%22%3A%5B5%2C6%5D%7D%2C%5B7%2C%5B8%2C9%5D%5D%2C10%2C11%5D'
   18    13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
175.81 ms | 1395 KiB | 15 Q