3v4l.org

run code in 300+ PHP versions simultaneously
<?php $characters = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'; $randomString = ''; for ($i = 0; $i < $length; $i++) { $randomString .= $characters[rand(0, strlen($characters) - 1)]; } print_r($randomString);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 13
Branch analysis from position: 13
2 jumps found. (Code = 44) Position 1 = 15, Position 2 = 4
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
2 jumps found. (Code = 44) Position 1 = 15, Position 2 = 4
Branch analysis from position: 15
Branch analysis from position: 4
filename:       /in/94laV
function name:  (null)
number of ops:  19
compiled vars:  !0 = $characters, !1 = $randomString, !2 = $i, !3 = $length
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'
    3     1        ASSIGN                                                   !1, ''
    4     2        ASSIGN                                                   !2, 0
          3      > JMP                                                      ->13
    5     4    >   INIT_FCALL                                               'rand'
          5        SEND_VAL                                                 0
          6        STRLEN                                           ~7      !0
          7        SUB                                              ~8      ~7, 1
          8        SEND_VAL                                                 ~8
          9        DO_ICALL                                         $9      
         10        FETCH_DIM_R                                      ~10     !0, $9
         11        ASSIGN_OP                                     8          !1, ~10
    4    12        PRE_INC                                                  !2
         13    >   IS_SMALLER                                               !2, !3
         14      > JMPNZ                                                    ~13, ->4
    7    15    >   INIT_FCALL                                               'print_r'
         16        SEND_VAR                                                 !1
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.1 ms | 1395 KiB | 17 Q