3v4l.org

run code in 300+ PHP versions simultaneously
<?php $facults = array('Леч. фак.' => 1, 'Пед. фак.' => 2, 'Стом. фак.' => 3, 'ВСО' => 4); $dog = ',Леч. фак.,Пед. фак.,'; for ($i=1; $i < (substr_count($dog, ',')); $i++) { echo $facults[(explode(',', $dog)[$i])]; echo $facults[(explode(',', $dog))[$i]]; echo $facults[explode(',', $dog)[$i]]; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
2 jumps found. (Code = 44) Position 1 = 32, Position 2 = 4
Branch analysis from position: 32
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
2 jumps found. (Code = 44) Position 1 = 32, Position 2 = 4
Branch analysis from position: 32
Branch analysis from position: 4
filename:       /in/NEo9F
function name:  (null)
number of ops:  33
compiled vars:  !0 = $facults, !1 = $dog, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN                                                   !1, '%2C%D0%9B%D0%B5%D1%87.+%D1%84%D0%B0%D0%BA.%2C%D0%9F%D0%B5%D0%B4.+%D1%84%D0%B0%D0%BA.%2C'
    4     2        ASSIGN                                                   !2, 1
          3      > JMP                                                      ->26
    5     4    >   INIT_FCALL                                               'explode'
          5        SEND_VAL                                                 '%2C'
          6        SEND_VAR                                                 !1
          7        DO_ICALL                                         $6      
          8        FETCH_DIM_R                                      ~7      $6, !2
          9        FETCH_DIM_R                                      ~8      !0, ~7
         10        ECHO                                                     ~8
    6    11        INIT_FCALL                                               'explode'
         12        SEND_VAL                                                 '%2C'
         13        SEND_VAR                                                 !1
         14        DO_ICALL                                         $9      
         15        FETCH_DIM_R                                      ~10     $9, !2
         16        FETCH_DIM_R                                      ~11     !0, ~10
         17        ECHO                                                     ~11
    7    18        INIT_FCALL                                               'explode'
         19        SEND_VAL                                                 '%2C'
         20        SEND_VAR                                                 !1
         21        DO_ICALL                                         $12     
         22        FETCH_DIM_R                                      ~13     $12, !2
         23        FETCH_DIM_R                                      ~14     !0, ~13
         24        ECHO                                                     ~14
    4    25        PRE_INC                                                  !2
         26    >   INIT_FCALL                                               'substr_count'
         27        SEND_VAR                                                 !1
         28        SEND_VAL                                                 '%2C'
         29        DO_ICALL                                         $16     
         30        IS_SMALLER                                               !2, $16
         31      > JMPNZ                                                    ~17, ->4
    8    32    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.52 ms | 1396 KiB | 17 Q