3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
186.31 ms | 1394 KiB | 15 Q