3v4l.org

run code in 300+ PHP versions simultaneously
<?php $category = array( '1' => 'Ctegory 1', '2' => 'Ctegory 2', '3' => 'Ctegory 3', ); $explodeID = explode(',', '3,1'); foreach($category as $key => $value){ if(in_array($key, $explodeID)){ echo "$key => $value" . PHP_EOL; } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 7, Position 2 = 20
Branch analysis from position: 7
2 jumps found. (Code = 78) Position 1 = 8, Position 2 = 20
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 19
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 19
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/RkkkA
function name:  (null)
number of ops:  22
compiled vars:  !0 = $category, !1 = $explodeID, !2 = $value, !3 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   10     1        INIT_FCALL                                               'explode'
          2        SEND_VAL                                                 '%2C'
          3        SEND_VAL                                                 '3%2C1'
          4        DO_ICALL                                         $5      
          5        ASSIGN                                                   !1, $5
   12     6      > FE_RESET_R                                       $7      !0, ->20
          7    > > FE_FETCH_R                                       ~8      $7, !2, ->20
          8    >   ASSIGN                                                   !3, ~8
   14     9        INIT_FCALL                                               'in_array'
         10        SEND_VAR                                                 !3
         11        SEND_VAR                                                 !1
         12        DO_ICALL                                         $10     
         13      > JMPZ                                                     $10, ->19
   15    14    >   ROPE_INIT                                     3  ~12     !3
         15        ROPE_ADD                                      1  ~12     ~12, '+%3D%3E+'
         16        ROPE_END                                      2  ~11     ~12, !2
         17        CONCAT                                           ~14     ~11, '%0A'
         18        ECHO                                                     ~14
   12    19    > > JMP                                                      ->7
         20    >   FE_FREE                                                  $7
   17    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.67 ms | 1395 KiB | 17 Q