3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = ['element1', 'element2', 'element3', 'element4']; $i = 0; do { if ($i != 1) { echo $array[$i] . PHP_EOL; } $i++; } while ($i < count($array)); foreach ($array as $key => $value) { if ($key != 1) { echo $value . PHP_EOL; } } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 7
Branch analysis from position: 4
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 2
Branch analysis from position: 11
2 jumps found. (Code = 77) Position 1 = 12, Position 2 = 19
Branch analysis from position: 12
2 jumps found. (Code = 78) Position 1 = 13, Position 2 = 19
Branch analysis from position: 13
2 jumps found. (Code = 43) Position 1 = 16, Position 2 = 18
Branch analysis from position: 16
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
Branch analysis from position: 18
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 19
Branch analysis from position: 2
Branch analysis from position: 7
filename:       /in/j2oCM
function name:  (null)
number of ops:  21
compiled vars:  !0 = $array, !1 = $i, !2 = $value, !3 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1        ASSIGN                                                   !1, 0
    7     2    >   IS_NOT_EQUAL                                             !1, 1
          3      > JMPZ                                                     ~6, ->7
    8     4    >   FETCH_DIM_R                                      ~7      !0, !1
          5        CONCAT                                           ~8      ~7, '%0A'
          6        ECHO                                                     ~8
   10     7    >   PRE_INC                                                  !1
   11     8        COUNT                                            ~10     !0
          9        IS_SMALLER                                               !1, ~10
         10      > JMPNZ                                                    ~11, ->2
   13    11    > > FE_RESET_R                                       $12     !0, ->19
         12    > > FE_FETCH_R                                       ~13     $12, !2, ->19
         13    >   ASSIGN                                                   !3, ~13
   14    14        IS_NOT_EQUAL                                             !3, 1
         15      > JMPZ                                                     ~15, ->18
   15    16    >   CONCAT                                           ~16     !2, '%0A'
         17        ECHO                                                     ~16
   13    18    > > JMP                                                      ->12
         19    >   FE_FREE                                                  $12
   18    20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.35 ms | 1394 KiB | 13 Q