3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.66 ms | 1394 KiB | 15 Q