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/eUtoH
function name:  (null)
number of ops:  22
compiled vars:  !0 = $dobPart, !1 = $prefix, !2 = $dobpart
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E > > FE_RESET_R                                       $3      <array>, ->20
          1    > > FE_FETCH_R                                               $3, !0, ->20
    4     2    >   INIT_FCALL                                               'substr'
          3        SEND_VAR                                                 !2
          4        SEND_VAL                                                 0
          5        SEND_VAL                                                 1
          6        DO_ICALL                                         $4      
          7        ASSIGN                                                   !1, $4
    5     8        INIT_FCALL                                               'str_repeat'
          9        SEND_VAR                                                 !1
         10        SEND_VAL                                                 1
         11        DO_ICALL                                         $6      
         12        ASSIGN                                                   !1, $6
    6    13        INIT_FCALL                                               'var_dump'
         14        INIT_FCALL                                               'strtoupper'
         15        SEND_VAR                                                 !1
         16        DO_ICALL                                         $8      
         17        SEND_VAR                                                 $8
         18        DO_ICALL                                                 
    3    19      > JMP                                                      ->1
         20    >   FE_FREE                                                  $3
    8    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.88 ms | 1395 KiB | 21 Q