3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = "hello;world;if(blah){blahcode}"; for($i = 0; $i < strlen($input); $i+=1) { switch($input[$i]) { case ";": $input[$i] += '\n'; break; } } echo $input; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 44) Position 1 = 15, Position 2 = 3
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 44) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
2 jumps found. (Code = 44) Position 1 = 15, Position 2 = 3
Branch analysis from position: 15
Branch analysis from position: 3
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
filename:       /in/Y2T85
function name:  (null)
number of ops:  17
compiled vars:  !0 = $input, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'hello%3Bworld%3Bif%28blah%29%7Bblahcode%7D'
    3     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->12
    5     3    >   FETCH_DIM_R                                      ~4      !0, !1
    7     4        CASE                                                     ~4, '%3B'
          5      > JMPNZ                                                    ~5, ->7
          6    > > JMP                                                      ->10
    8     7    >   ASSIGN_DIM_OP                +=               1          !0, !1
          8        OP_DATA                                                  '%5Cn'
    9     9      > JMP                                                      ->10
         10    >   FREE                                                     ~4
    3    11        ASSIGN_OP                                     1          !1, 1
         12    >   STRLEN                                           ~8      !0
         13        IS_SMALLER                                               !1, ~8
         14      > JMPNZ                                                    ~9, ->3
   12    15    >   ECHO                                                     !0
   13    16      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.4 ms | 1393 KiB | 13 Q