3v4l.org

run code in 300+ PHP versions simultaneously
<?php $var = "12345"; echo $var[0] . "-" . substr($var,0);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/J42P1
function name:  (null)
number of ops:  10
compiled vars:  !0 = $var
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '12345'
    4     1        FETCH_DIM_R                                      ~2      !0, 0
          2        CONCAT                                           ~3      ~2, '-'
          3        INIT_FCALL                                               'substr'
          4        SEND_VAR                                                 !0
          5        SEND_VAL                                                 0
          6        DO_ICALL                                         $4      
          7        CONCAT                                           ~5      ~3, $4
          8        ECHO                                                     ~5
          9      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.32 ms | 1385 KiB | 15 Q