3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [ [ 'month' => 'June', 'sale' => 98765 ], [ 'month' => 'May', 'sale' => 45678 ], [ 'month' => 'April', 'sale' => 213456 ], [ 'month' => 'August', 'sale' => 23456 ], [ 'month' => 'July', 'sale' => 12376 ], ]; $month_array = array_column($array,'month'); $sale_array = array_column($array,'sale'); print_r($month_array); print_r($sale_array);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ancBB
function name:  (null)
number of ops:  18
compiled vars:  !0 = $array, !1 = $month_array, !2 = $sale_array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   26     1        INIT_FCALL                                               'array_column'
          2        SEND_VAR                                                 !0
          3        SEND_VAL                                                 'month'
          4        DO_ICALL                                         $4      
          5        ASSIGN                                                   !1, $4
   27     6        INIT_FCALL                                               'array_column'
          7        SEND_VAR                                                 !0
          8        SEND_VAL                                                 'sale'
          9        DO_ICALL                                         $6      
         10        ASSIGN                                                   !2, $6
   29    11        INIT_FCALL                                               'print_r'
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                                 
   30    14        INIT_FCALL                                               'print_r'
         15        SEND_VAR                                                 !2
         16        DO_ICALL                                                 
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
205.77 ms | 1002 KiB | 15 Q