3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = [0,1,2,3,4,5,6]; $count = count($a); for($i=0;$i<$count;$i++){ echo 's ' . $i.' ' .$a[$i] .PHP_EOL; if ($a[$i]==3) { unset($a[$i]); $count--; $i--; $a=array_merge($a); } echo 'e ' . $i.' ' .$a[$i] .PHP_EOL; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 28
Branch analysis from position: 28
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 5
Branch analysis from position: 30
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 21
Branch analysis from position: 14
2 jumps found. (Code = 44) Position 1 = 30, Position 2 = 5
Branch analysis from position: 30
Branch analysis from position: 5
Branch analysis from position: 21
filename:       /in/OI6LR
function name:  (null)
number of ops:  31
compiled vars:  !0 = $a, !1 = $count, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        COUNT                                            ~4      !0
          2        ASSIGN                                                   !1, ~4
    4     3        ASSIGN                                                   !2, 0
          4      > JMP                                                      ->28
    5     5    >   CONCAT                                           ~7      's+', !2
          6        CONCAT                                           ~8      ~7, '+'
          7        FETCH_DIM_R                                      ~9      !0, !2
          8        CONCAT                                           ~10     ~8, ~9
          9        CONCAT                                           ~11     ~10, '%0A'
         10        ECHO                                                     ~11
    6    11        FETCH_DIM_R                                      ~12     !0, !2
         12        IS_EQUAL                                                 ~12, 3
         13      > JMPZ                                                     ~13, ->21
    7    14    >   UNSET_DIM                                                !0, !2
    8    15        PRE_DEC                                                  !1
    9    16        PRE_DEC                                                  !2
   10    17        INIT_FCALL                                               'array_merge'
         18        SEND_VAR                                                 !0
         19        DO_ICALL                                         $16     
         20        ASSIGN                                                   !0, $16
   12    21    >   CONCAT                                           ~18     'e+', !2
         22        CONCAT                                           ~19     ~18, '+'
         23        FETCH_DIM_R                                      ~20     !0, !2
         24        CONCAT                                           ~21     ~19, ~20
         25        CONCAT                                           ~22     ~21, '%0A'
         26        ECHO                                                     ~22
    4    27        PRE_INC                                                  !2
         28    >   IS_SMALLER                                               !2, !1
         29      > JMPNZ                                                    ~24, ->5
   13    30    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.56 ms | 1396 KiB | 15 Q