3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.81 ms | 1394 KiB | 13 Q