3v4l.org

run code in 300+ PHP versions simultaneously
<?php foreach(array('day', 'month', 'year') as $dobPart) { $prefix = substr($dobPart,0,1); $prefix = str_repeat($prefix,1); var_dump(strtoupper($prefix)); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 1, Position 2 = 20
Branch analysis from position: 1
2 jumps found. (Code = 78) Position 1 = 2, Position 2 = 20
Branch analysis from position: 2
1 jumps found. (Code = 42) Position 1 = 1
Branch analysis from position: 1
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/m5WVF
function name:  (null)
number of ops:  22
compiled vars:  !0 = $dobPart, !1 = $prefix
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E > > FE_RESET_R                                       $2      <array>, ->20
          1    > > FE_FETCH_R                                               $2, !0, ->20
    4     2    >   INIT_FCALL                                               'substr'
          3        SEND_VAR                                                 !0
          4        SEND_VAL                                                 0
          5        SEND_VAL                                                 1
          6        DO_ICALL                                         $3      
          7        ASSIGN                                                   !1, $3
    5     8        INIT_FCALL                                               'str_repeat'
          9        SEND_VAR                                                 !1
         10        SEND_VAL                                                 1
         11        DO_ICALL                                         $5      
         12        ASSIGN                                                   !1, $5
    6    13        INIT_FCALL                                               'var_dump'
         14        INIT_FCALL                                               'strtoupper'
         15        SEND_VAR                                                 !1
         16        DO_ICALL                                         $7      
         17        SEND_VAR                                                 $7
         18        DO_ICALL                                                 
    3    19      > JMP                                                      ->1
         20    >   FE_FREE                                                  $2
    8    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.24 ms | 1395 KiB | 21 Q