3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array=Array ( 0 => Array ( "Title" => "La science des rĂªves", "Year" => "2006", "Director" => Array ( "Name" => "Michel Gondry", "BirthYear" => "1963", "BirthPlace" => "Versailles, Yvelines, France" ) ), 1 => Array ( "Title" => "Arizona Dream", "Year" => "1992", "Director" => Array ( "Name" => "Emir Kusturica", "BirthYear" => "1954", "BirthPlace" => "Sarajevo, Bosnia and Herzegovina, Yugoslavia" ) ) ); $ck=Array ( 0 => "Title", 1 => "Director.Name", 2 => "Director.BirthYear" ); echo '<pre>'; print_r($array); echo '</pre>'; foreach($array as $final) { $final_array[] = array( 'title'=>$final['Title'], 'name'=>$final['Director']['Name'], 'birthyear'=> $final['Director']['BirthYear'] ); } echo '<pre>'; print_r($final_array); echo '</pre>';
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 20
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 20
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/0B4BX
function name:  (null)
number of ops:  27
compiled vars:  !0 = $array, !1 = $ck, !2 = $final, !3 = $final_array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   33     1        ASSIGN                                                   !1, <array>
   41     2        ECHO                                                     '%3Cpre%3E'
   42     3        INIT_FCALL                                               'print_r'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                                 
   43     6        ECHO                                                     '%3C%2Fpre%3E'
   45     7      > FE_RESET_R                                       $7      !0, ->20
          8    > > FE_FETCH_R                                               $7, !2, ->20
   49     9    >   FETCH_DIM_R                                      ~9      !2, 'Title'
         10        INIT_ARRAY                                       ~10     ~9, 'title'
   50    11        FETCH_DIM_R                                      ~11     !2, 'Director'
         12        FETCH_DIM_R                                      ~12     ~11, 'Name'
         13        ADD_ARRAY_ELEMENT                                ~10     ~12, 'name'
   51    14        FETCH_DIM_R                                      ~13     !2, 'Director'
         15        FETCH_DIM_R                                      ~14     ~13, 'BirthYear'
         16        ADD_ARRAY_ELEMENT                                ~10     ~14, 'birthyear'
   48    17        ASSIGN_DIM                                               !3
   51    18        OP_DATA                                                  ~10
   45    19      > JMP                                                      ->8
         20    >   FE_FREE                                                  $7
   56    21        ECHO                                                     '%3Cpre%3E'
   57    22        INIT_FCALL                                               'print_r'
         23        SEND_VAR                                                 !3
         24        DO_ICALL                                                 
   58    25        ECHO                                                     '%3C%2Fpre%3E'
         26      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.85 ms | 1387 KiB | 15 Q