3v4l.org

run code in 300+ PHP versions simultaneously
<?php $mystring = "aHR0cHM6Ly93d3cucGhwLm5ldC9tYW51YWwvZW4vZnVuY3Rpb24uc3RyLXNwbGl0LnBocA=="; $len = strlen($mystring); $end_of_first = rand(1, $len - 2); $end_of_middle = rand(1, $len - $end_of_first - 1); $result = sscanf($mystring, "%{$end_of_first}s%{$end_of_middle}s%s"); var_export($result); echo "\n---\n"; var_export(compact(['len', 'end_of_first', 'end_of_middle']) + ['implodedCount' => strlen(implode($result))]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sLndj
function name:  (null)
number of ops:  43
compiled vars:  !0 = $mystring, !1 = $len, !2 = $end_of_first, !3 = $end_of_middle, !4 = $result
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'aHR0cHM6Ly93d3cucGhwLm5ldC9tYW51YWwvZW4vZnVuY3Rpb24uc3RyLXNwbGl0LnBocA%3D%3D'
    5     1        STRLEN                                           ~6      !0
          2        ASSIGN                                                   !1, ~6
    6     3        INIT_FCALL                                               'rand'
          4        SEND_VAL                                                 1
          5        SUB                                              ~8      !1, 2
          6        SEND_VAL                                                 ~8
          7        DO_ICALL                                         $9      
          8        ASSIGN                                                   !2, $9
    7     9        INIT_FCALL                                               'rand'
         10        SEND_VAL                                                 1
         11        SUB                                              ~11     !1, !2
         12        SUB                                              ~12     ~11, 1
         13        SEND_VAL                                                 ~12
         14        DO_ICALL                                         $13     
         15        ASSIGN                                                   !3, $13
    9    16        INIT_FCALL                                               'sscanf'
         17        SEND_VAR                                                 !0
         18        ROPE_INIT                                     5  ~16     '%25'
         19        ROPE_ADD                                      1  ~16     ~16, !2
         20        ROPE_ADD                                      2  ~16     ~16, 's%25'
         21        ROPE_ADD                                      3  ~16     ~16, !3
         22        ROPE_END                                      4  ~15     ~16, 's%25s'
         23        SEND_VAL                                                 ~15
         24        DO_ICALL                                         $19     
         25        ASSIGN                                                   !4, $19
   11    26        INIT_FCALL                                               'var_export'
         27        SEND_VAR                                                 !4
         28        DO_ICALL                                                 
   13    29        ECHO                                                     '%0A---%0A'
   15    30        INIT_FCALL                                               'var_export'
         31        INIT_FCALL                                               'compact'
         32        SEND_VAL                                                 <array>
         33        DO_ICALL                                         $22     
         34        INIT_FCALL                                               'implode'
         35        SEND_VAR                                                 !4
         36        DO_ICALL                                         $23     
         37        STRLEN                                           ~24     $23
         38        INIT_ARRAY                                       ~25     ~24, 'implodedCount'
         39        ADD                                              ~26     $22, ~25
         40        SEND_VAL                                                 ~26
         41        DO_ICALL                                                 
         42      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.91 ms | 1015 KiB | 18 Q