3v4l.org

run code in 300+ PHP versions simultaneously
<?php $intro = array( array( "name"=>"Peter","age"=>"40","location"=>"USA" ), array("name"=>"Mike","age"=>"55","location"=>"USA") ); $bikes = array( array( "brand"=>"Hero","cc"=>"150", "rpm"=>"8500"), array( "brand"=>"Honda","cc"=>"150", "rpm"=>"9500") ); $result = array_map(function($a, $b) { return array_merge($a, $b); }, $intro, $bikes); print_r($result);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jrJQd
function name:  (null)
number of ops:  13
compiled vars:  !0 = $intro, !1 = $bikes, !2 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    7     1        ASSIGN                                                   !1, <array>
   11     2        INIT_FCALL                                               'array_map'
          3        DECLARE_LAMBDA_FUNCTION                          ~5      [0]
   13     4        SEND_VAL                                                 ~5
          5        SEND_VAR                                                 !0
          6        SEND_VAR                                                 !1
   11     7        DO_ICALL                                         $6      
          8        ASSIGN                                                   !2, $6
   15     9        INIT_FCALL                                               'print_r'
         10        SEND_VAR                                                 !2
         11        DO_ICALL                                                 
         12      > RETURN                                                   1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/jrJQd
function name:  {closure}
number of ops:  8
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   12     2        INIT_FCALL                                               'array_merge'
          3        SEND_VAR                                                 !0
          4        SEND_VAR                                                 !1
          5        DO_ICALL                                         $2      
          6      > RETURN                                                   $2
   13     7*     > RETURN                                                   null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
150.97 ms | 1003 KiB | 16 Q