3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $array = [ [ 'a' => 1, 'b' => 2, 'c' => 3], [ 'a' => 4, 'b' => 5, 'c' => 6], [ 'a' => 7, 'b' => 8, 'c' => 9] ]; $column = array_column($array, 'a'); foreach ($array as &$val) { unset($val['a']); } // ПРОБЛЕМА РЕШЕНА for ($i = 0; $i < 3; ++$i) { echo implode(', ', $array[i]) . "\n"; } // !!! if (!empty($array)) { echo ' _______' . PHP_EOL . '| '; foreach ($array[0] as $key => $val) { echo $key . ' | '; } echo PHP_EOL . ' -------' . PHP_EOL; foreach ($array as $val) { echo '| '; foreach($val as $key => $veryVal) { echo $veryVal . ' | '; } echo PHP_EOL; } echo ' -------'; }
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = 7, Position 2 = 10
Branch analysis from position: 7
Jump found. Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
Jump found. Position 1 = 7
Branch analysis from position: 7
Branch analysis from position: 10
Jump found. Position 1 = 22
Branch analysis from position: 22
Jump found. Position 1 = 24, Position 2 = 13
Branch analysis from position: 24
Jump found. Position 1 = 27, Position 2 = 51
Branch analysis from position: 27
Jump found. Position 1 = 30, Position 2 = 35
Branch analysis from position: 30
Jump found. Position 1 = 31, Position 2 = 35
Branch analysis from position: 31
Jump found. Position 1 = 30
Branch analysis from position: 30
Branch analysis from position: 35
Jump found. Position 1 = 38, Position 2 = 49
Branch analysis from position: 38
Jump found. Position 1 = 39, Position 2 = 49
Branch analysis from position: 39
Jump found. Position 1 = 41, Position 2 = 46
Branch analysis from position: 41
Jump found. Position 1 = 42, Position 2 = 46
Branch analysis from position: 42
Jump found. Position 1 = 41
Branch analysis from position: 41
Branch analysis from position: 46
Jump found. Position 1 = 38
Branch analysis from position: 38
Branch analysis from position: 46
Branch analysis from position: 49
Jump found. Position 1 = -2
Branch analysis from position: 49
Branch analysis from position: 35
Branch analysis from position: 51
Branch analysis from position: 13
Jump found. Position 1 = 24, Position 2 = 13
Branch analysis from position: 24
Branch analysis from position: 13
Branch analysis from position: 10
filename:       /in/uC9kI
function name:  (null)
number of ops:  52
compiled vars:  !0 = $array, !1 = $column, !2 = $val, !3 = $i, !4 = $key, !5 = $veryVal
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   3     0  E >   ASSIGN                                                   !0, <array>
   8     1        INIT_FCALL                                               'array_column'
         2        SEND_VAR                                                 !0
         3        SEND_VAL                                                 'a'
         4        DO_ICALL                                         $7      
         5        ASSIGN                                                   !1, $7
   9     6      > FE_RESET_RW                                      $9      !0, ->10
         7    > > FE_FETCH_RW                                              $9, !2, ->10
  10     8    >   UNSET_DIM                                                !2, 'a'
         9      > JMP                                                      ->7
        10    >   FE_FREE                                                  $9
  13    11        ASSIGN                                                   !3, 0
        12      > JMP                                                      ->22
  14    13    >   INIT_FCALL                                               'implode'
        14        SEND_VAL                                                 '%2C+'
        15        FETCH_CONSTANT                                   ~11     'i'
        16        FETCH_DIM_R                                      $12     !0, ~11
        17        SEND_VAR                                                 $12
        18        DO_ICALL                                         $13     
        19        CONCAT                                           ~14     $13, '%0A'
        20        ECHO                                                     ~14
  13    21        PRE_INC                                                  !3
        22    >   IS_SMALLER                                       ~16     !3, 3
        23      > JMPNZ                                                    ~16, ->13
  17    24    >   ISSET_ISEMPTY_VAR                           293601280  ~17     !0
        25        BOOL_NOT                                         ~18     ~17
        26      > JMPZ                                                     ~18, ->51
  18    27    >   ECHO                                                     '+_______%0A%7C+'
  19    28        FETCH_DIM_R                                      $19     !0, 0
        29      > FE_RESET_R                                       $20     $19, ->35
        30    > > FE_FETCH_R                                               $20, !2, ->35
        31    >   ASSIGN                                                   !4, ~21
  20    32        CONCAT                                           ~23     !4, '+%7C+'
        33        ECHO                                                     ~23
        34      > JMP                                                      ->30
        35    >   FE_FREE                                                  $20
  22    36        ECHO                                                     '%0A+-------%0A'
  23    37      > FE_RESET_R                                       $24     !0, ->49
        38    > > FE_FETCH_R                                               $24, !2, ->49
  24    39    >   ECHO                                                     '%7C+'
  25    40      > FE_RESET_R                                       $25     !2, ->46
        41    > > FE_FETCH_R                                               $25, !5, ->46
        42    >   ASSIGN                                                   !4, ~26
  26    43        CONCAT                                           ~28     !5, '+%7C+'
        44        ECHO                                                     ~28
        45      > JMP                                                      ->41
        46    >   FE_FREE                                                  $25
  28    47        ECHO                                                     '%0A'
        48      > JMP                                                      ->38
        49    >   FE_FREE                                                  $24
  30    50        ECHO                                                     '+-------'
        51    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 7.2.0