3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array('a', 'b', 'c', 'd', null); for($i = 0; $i < count($a); $i += 2) { echo $i . " "; if (array_key_exists($i + 1, $a)) { echo $a[$i + 1] . " "; } echo ($i + 1) . PHP_EOL; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 19, Position 2 = 3
Branch analysis from position: 19
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 12
Branch analysis from position: 8
2 jumps found. (Code = 44) Position 1 = 19, Position 2 = 3
Branch analysis from position: 19
Branch analysis from position: 3
Branch analysis from position: 12
filename:       /in/HKkFS
function name:  (null)
number of ops:  20
compiled vars:  !0 = $a, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->16
    5     3    >   CONCAT                                           ~4      !1, '+'
          4        ECHO                                                     ~4
    6     5        ADD                                              ~5      !1, 1
          6        ARRAY_KEY_EXISTS                                         ~5, !0
          7      > JMPZ                                                     ~6, ->12
    7     8    >   ADD                                              ~7      !1, 1
          9        FETCH_DIM_R                                      ~8      !0, ~7
         10        CONCAT                                           ~9      ~8, '+'
         11        ECHO                                                     ~9
    9    12    >   ADD                                              ~10     !1, 1
         13        CONCAT                                           ~11     ~10, '%0A'
         14        ECHO                                                     ~11
    4    15        ASSIGN_OP                                     1          !1, 2
         16    >   COUNT                                            ~13     !0
         17        IS_SMALLER                                               !1, ~13
         18      > JMPNZ                                                    ~14, ->3
   10    19    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.66 ms | 1393 KiB | 13 Q