3v4l.org

run code in 300+ PHP versions simultaneously
<?php $phone = '0312345678'; $phone = '09012345678'; echo strlen($phone), "\n"; $return[] = substr($phone, -4); $return[] = substr($phone, -4, 8); echo $phone, "\n"; var_dump($return);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Fbh1W
function name:  (null)
number of ops:  24
compiled vars:  !0 = $phone, !1 = $return
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '0312345678'
    3     1        ASSIGN                                                   !0, '09012345678'
    5     2        STRLEN                                           ~4      !0
          3        ECHO                                                     ~4
          4        ECHO                                                     '%0A'
    7     5        INIT_FCALL                                               'substr'
          6        SEND_VAR                                                 !0
          7        SEND_VAL                                                 -4
          8        DO_ICALL                                         $6      
          9        ASSIGN_DIM                                               !1
         10        OP_DATA                                                  $6
    8    11        INIT_FCALL                                               'substr'
         12        SEND_VAR                                                 !0
         13        SEND_VAL                                                 -4
         14        SEND_VAL                                                 8
         15        DO_ICALL                                         $8      
         16        ASSIGN_DIM                                               !1
         17        OP_DATA                                                  $8
    9    18        ECHO                                                     !0
         19        ECHO                                                     '%0A'
   10    20        INIT_FCALL                                               'var_dump'
         21        SEND_VAR                                                 !1
         22        DO_ICALL                                                 
         23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.64 ms | 1395 KiB | 17 Q