3v4l.org

run code in 300+ PHP versions simultaneously
<?php $found = null; $people = array(3,20,2); $criminals = array( 2, 4, 8, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20); foreach($people as $num) { if (in_array($num,$criminals)) { $found[$num] = true; } } var_dump($found);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 4, Position 2 = 13
Branch analysis from position: 4
2 jumps found. (Code = 78) Position 1 = 5, Position 2 = 13
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 12
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 4
Branch analysis from position: 4
Branch analysis from position: 12
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
filename:       /in/WGhO7
function name:  (null)
number of ops:  18
compiled vars:  !0 = $found, !1 = $people, !2 = $criminals, !3 = $num
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, null
    3     1        ASSIGN                                                   !1, <array>
    4     2        ASSIGN                                                   !2, <array>
    5     3      > FE_RESET_R                                       $7      !1, ->13
          4    > > FE_FETCH_R                                               $7, !3, ->13
    6     5    >   INIT_FCALL                                               'in_array'
          6        SEND_VAR                                                 !3
          7        SEND_VAR                                                 !2
          8        DO_ICALL                                         $8      
          9      > JMPZ                                                     $8, ->12
    7    10    >   ASSIGN_DIM                                               !0, !3
         11        OP_DATA                                                  <true>
    5    12    > > JMP                                                      ->4
         13    >   FE_FREE                                                  $7
   10    14        INIT_FCALL                                               'var_dump'
         15        SEND_VAR                                                 !0
         16        DO_ICALL                                                 
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.59 ms | 1460 KiB | 15 Q