3v4l.org

run code in 300+ PHP versions simultaneously
<?php $model = array(array('discount' => '2000', 'ids' => '100,1000,1000,1000'), array('discount' => '2001', 'ids' => '100,1000,1000,1000'),array('discount' => '2002', 'ids' => '100,1000,1000,1000')); foreach ($model as $k=> $mod) { $mod_2 = preg_filter('/^/', 'IC ', explode(',', $mod[ids])); print_r($mod_2); //echo $mod[discount].'-'.$mod_2[ids]; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 20
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 20
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/U24ek
function name:  (null)
number of ops:  22
compiled vars:  !0 = $model, !1 = $mod, !2 = $k, !3 = $mod_2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1      > FE_RESET_R                                       $5      !0, ->20
          2    > > FE_FETCH_R                                       ~6      $5, !1, ->20
          3    >   ASSIGN                                                   !2, ~6
    4     4        INIT_FCALL                                               'preg_filter'
          5        SEND_VAL                                                 '%2F%5E%2F'
          6        SEND_VAL                                                 'IC+'
          7        INIT_FCALL                                               'explode'
          8        SEND_VAL                                                 '%2C'
          9        FETCH_CONSTANT                                   ~8      'ids'
         10        FETCH_DIM_R                                      ~9      !1, ~8
         11        SEND_VAL                                                 ~9
         12        DO_ICALL                                         $10     
         13        SEND_VAR                                                 $10
         14        DO_ICALL                                         $11     
         15        ASSIGN                                                   !3, $11
    5    16        INIT_FCALL                                               'print_r'
         17        SEND_VAR                                                 !3
         18        DO_ICALL                                                 
    3    19      > JMP                                                      ->2
         20    >   FE_FREE                                                  $5
    7    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.69 ms | 1399 KiB | 19 Q