3v4l.org

run code in 500+ PHP versions simultaneously
<?php $a = array_slice($_SERVER, 0, 1); $b = array_slice($_SERVER, -1, 1, true); print_r($a); print_r($b); print_r($_SERVER); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GhoFm
function name:  (null)
number of ops:  26
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                                   'array_slice'
          1        FETCH_R                          global              ~2      '_SERVER'
          2        SEND_VAL                                                     ~2
          3        SEND_VAL                                                     0
          4        SEND_VAL                                                     1
          5        DO_ICALL                                             $3      
          6        ASSIGN                                                       !0, $3
    3     7        INIT_FCALL                                                   'array_slice'
          8        FETCH_R                          global              ~5      '_SERVER'
          9        SEND_VAL                                                     ~5
         10        SEND_VAL                                                     -1
         11        SEND_VAL                                                     1
         12        SEND_VAL                                                     <true>
         13        DO_ICALL                                             $6      
         14        ASSIGN                                                       !1, $6
    4    15        INIT_FCALL                                                   'print_r'
         16        SEND_VAR                                                     !0
         17        DO_ICALL                                                     
    5    18        INIT_FCALL                                                   'print_r'
         19        SEND_VAR                                                     !1
         20        DO_ICALL                                                     
    6    21        INIT_FCALL                                                   'print_r'
         22        FETCH_R                          global              ~10     '_SERVER'
         23        SEND_VAL                                                     ~10
         24        DO_ICALL                                                     
    7    25      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
164.42 ms | 2756 KiB | 15 Q