3v4l.org

run code in 300+ PHP versions simultaneously
<?php function randomPassword() { $currentmonth = date('n') - 1; $alphabet = "abcdefghijklm"; $random_hash = substr(md5(uniqid(rand(), true)), 28, 4); return $random_hash . substr($alphabet, $currentmonth, 1); } echo randomPassword();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/FWcka
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'randompassword'
          1        DO_FCALL                                      0  $0      
          2        ECHO                                                     $0
          3      > RETURN                                                   1

Function randompassword:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/FWcka
function name:  randomPassword
number of ops:  29
compiled vars:  !0 = $currentmonth, !1 = $alphabet, !2 = $random_hash
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   INIT_FCALL                                               'date'
          1        SEND_VAL                                                 'n'
          2        DO_ICALL                                         $3      
          3        SUB                                              ~4      $3, 1
          4        ASSIGN                                                   !0, ~4
    5     5        ASSIGN                                                   !1, 'abcdefghijklm'
    6     6        INIT_FCALL                                               'substr'
          7        INIT_FCALL                                               'md5'
          8        INIT_FCALL                                               'uniqid'
          9        INIT_FCALL                                               'rand'
         10        DO_ICALL                                         $7      
         11        SEND_VAR                                                 $7
         12        SEND_VAL                                                 <true>
         13        DO_ICALL                                         $8      
         14        SEND_VAR                                                 $8
         15        DO_ICALL                                         $9      
         16        SEND_VAR                                                 $9
         17        SEND_VAL                                                 28
         18        SEND_VAL                                                 4
         19        DO_ICALL                                         $10     
         20        ASSIGN                                                   !2, $10
    7    21        INIT_FCALL                                               'substr'
         22        SEND_VAR                                                 !1
         23        SEND_VAR                                                 !0
         24        SEND_VAL                                                 1
         25        DO_ICALL                                         $12     
         26        CONCAT                                           ~13     !2, $12
         27      > RETURN                                                   ~13
    8    28*     > RETURN                                                   null

End of function randompassword

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.59 ms | 1013 KiB | 19 Q