3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array('ishita','jayesh','shalin','miraj','shalini','av','gh'); $b = array(); $j = 1; for ($i = 0; $i < sizeof($a); $i++) { if($j != 7) { array_push($b,$a[$i]); $j= $j+1; } else { $j = 1; print_r($b); exit; } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 21
Branch analysis from position: 21
2 jumps found. (Code = 44) Position 1 = 24, Position 2 = 5
Branch analysis from position: 24
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 7, Position 2 = 15
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 20
Branch analysis from position: 20
2 jumps found. (Code = 44) Position 1 = 24, Position 2 = 5
Branch analysis from position: 24
Branch analysis from position: 5
Branch analysis from position: 15
1 jumps found. (Code = 79) Position 1 = -2
filename:       /in/1sjF5
function name:  (null)
number of ops:  25
compiled vars:  !0 = $a, !1 = $b, !2 = $j, !3 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN                                                   !1, <array>
    4     2        ASSIGN                                                   !2, 1
    5     3        ASSIGN                                                   !3, 0
          4      > JMP                                                      ->21
    6     5    >   IS_NOT_EQUAL                                             !2, 7
          6      > JMPZ                                                     ~8, ->15
    7     7    >   INIT_FCALL                                               'array_push'
          8        SEND_REF                                                 !1
          9        FETCH_DIM_R                                      ~9      !0, !3
         10        SEND_VAL                                                 ~9
         11        DO_ICALL                                                 
    8    12        ADD                                              ~11     !2, 1
         13        ASSIGN                                                   !2, ~11
         14      > JMP                                                      ->20
   10    15    >   ASSIGN                                                   !2, 1
   11    16        INIT_FCALL                                               'print_r'
         17        SEND_VAR                                                 !1
         18        DO_ICALL                                                 
   12    19      > EXIT                                                     
    5    20    >   PRE_INC                                                  !3
         21    >   COUNT                                            ~16     !0
         22        IS_SMALLER                                               !3, ~16
         23      > JMPNZ                                                    ~17, ->5
   14    24    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.81 ms | 1395 KiB | 17 Q