3v4l.org

run code in 300+ PHP versions simultaneously
<?php $KEY_BASE = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; $BASE = 62; $num = 11112887; $num = array_map('intval',str_split($num)); $result = ''; $remainder = ''; foreach ($num as $digit) { $remainder = $num%$BASE; $result.=$KEY_BASE[$remainder]; //echo $digit; } echo $result;
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 14, Position 2 = 20
Branch analysis from position: 14
2 jumps found. (Code = 78) Position 1 = 15, Position 2 = 20
Branch analysis from position: 15
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/eUkjn
function name:  (null)
number of ops:  23
compiled vars:  !0 = $KEY_BASE, !1 = $BASE, !2 = $num, !3 = $result, !4 = $remainder, !5 = $digit
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'
    3     1        ASSIGN                                                   !1, 62
    4     2        ASSIGN                                                   !2, 11112887
    5     3        INIT_FCALL                                               'array_map'
          4        SEND_VAL                                                 'intval'
          5        INIT_FCALL                                               'str_split'
          6        SEND_VAR                                                 !2
          7        DO_ICALL                                         $9      
          8        SEND_VAR                                                 $9
          9        DO_ICALL                                         $10     
         10        ASSIGN                                                   !2, $10
    6    11        ASSIGN                                                   !3, ''
    7    12        ASSIGN                                                   !4, ''
    8    13      > FE_RESET_R                                       $14     !2, ->20
         14    > > FE_FETCH_R                                               $14, !5, ->20
    9    15    >   MOD                                              ~15     !2, !1
         16        ASSIGN                                                   !4, ~15
   10    17        FETCH_DIM_R                                      ~17     !0, !4
         18        ASSIGN_OP                                     8          !3, ~17
    8    19      > JMP                                                      ->14
         20    >   FE_FREE                                                  $14
   13    21        ECHO                                                     !3
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.31 ms | 1395 KiB | 17 Q