3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr=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" ); $newarray=array(); foreach($ck as $ck2) { $k = explode(".",$ck2); print_r($k[0]); echo sizeof($k); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 4, Position 2 = 17
Branch analysis from position: 4
2 jumps found. (Code = 78) Position 1 = 5, Position 2 = 17
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 4
Branch analysis from position: 4
Branch analysis from position: 17
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 17
filename:       /in/SQ5AE
function name:  (null)
number of ops:  19
compiled vars:  !0 = $arr, !1 = $ck, !2 = $newarray, !3 = $ck2, !4 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   33     1        ASSIGN                                                   !1, <array>
   41     2        ASSIGN                                                   !2, <array>
   43     3      > FE_RESET_R                                       $8      !1, ->17
          4    > > FE_FETCH_R                                               $8, !3, ->17
   45     5    >   INIT_FCALL                                               'explode'
          6        SEND_VAL                                                 '.'
          7        SEND_VAR                                                 !3
          8        DO_ICALL                                         $9      
          9        ASSIGN                                                   !4, $9
   46    10        INIT_FCALL                                               'print_r'
         11        FETCH_DIM_R                                      ~11     !4, 0
         12        SEND_VAL                                                 ~11
         13        DO_ICALL                                                 
   47    14        COUNT                                            ~13     !4
         15        ECHO                                                     ~13
   43    16      > JMP                                                      ->4
         17    >   FE_FREE                                                  $8
   48    18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.97 ms | 1386 KiB | 17 Q