3v4l.org

run code in 300+ PHP versions simultaneously
<?php // http://williamsoriscompetition.com/enter.php?id=c54eaaa334be71e3da26536ffb365337185985da&score=1%2E926627&code=960349492860 $id = 'c54eaaa334be71e3da26536ffb365337185985da'; $score = urldecode('1%2E926627'); var_dump($score); $num1 = toInt32(substr($id, 0, 1)) * toInt32(substr($id, -1, 1)); $num2 = toInt32(substr($score, 0, 1)) * toInt32(substr($id, 3, 1)); $num3 = toInt32(substr($id, 2, 1)) * toInt32(substr($id, -1, 1)); $code = $num1 . $num2 . $num3; var_dump($code); function toInt32($value) { $intval = hexdec($value); var_dump($value, $intval); return (PHP_INT_SIZE === 8) ? ($intval - 0x100000000) : $intval; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m4Vdi
function name:  (null)
number of ops:  69
compiled vars:  !0 = $id, !1 = $score, !2 = $num1, !3 = $num2, !4 = $num3, !5 = $code
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   ASSIGN                                                   !0, 'c54eaaa334be71e3da26536ffb365337185985da'
    7     1        INIT_FCALL                                               'urldecode'
          2        SEND_VAL                                                 '1%252E926627'
          3        DO_ICALL                                         $7      
          4        ASSIGN                                                   !1, $7
    8     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !1
          7        DO_ICALL                                                 
   10     8        INIT_FCALL_BY_NAME                                       'toInt32'
          9        INIT_FCALL                                               'substr'
         10        SEND_VAR                                                 !0
         11        SEND_VAL                                                 0
         12        SEND_VAL                                                 1
         13        DO_ICALL                                         $10     
         14        SEND_VAR_NO_REF_EX                                       $10
         15        DO_FCALL                                      0  $11     
         16        INIT_FCALL_BY_NAME                                       'toInt32'
         17        INIT_FCALL                                               'substr'
         18        SEND_VAR                                                 !0
         19        SEND_VAL                                                 -1
         20        SEND_VAL                                                 1
         21        DO_ICALL                                         $12     
         22        SEND_VAR_NO_REF_EX                                       $12
         23        DO_FCALL                                      0  $13     
         24        MUL                                              ~14     $11, $13
         25        ASSIGN                                                   !2, ~14
   11    26        INIT_FCALL_BY_NAME                                       'toInt32'
         27        INIT_FCALL                                               'substr'
         28        SEND_VAR                                                 !1
         29        SEND_VAL                                                 0
         30        SEND_VAL                                                 1
         31        DO_ICALL                                         $16     
         32        SEND_VAR_NO_REF_EX                                       $16
         33        DO_FCALL                                      0  $17     
         34        INIT_FCALL_BY_NAME                                       'toInt32'
         35        INIT_FCALL                                               'substr'
         36        SEND_VAR                                                 !0
         37        SEND_VAL                                                 3
         38        SEND_VAL                                                 1
         39        DO_ICALL                                         $18     
         40        SEND_VAR_NO_REF_EX                                       $18
         41        DO_FCALL                                      0  $19     
         42        MUL                                              ~20     $17, $19
         43        ASSIGN                                                   !3, ~20
   12    44        INIT_FCALL_BY_NAME                                       'toInt32'
         45        INIT_FCALL                                               'substr'
         46        SEND_VAR                                                 !0
         47        SEND_VAL                                                 2
         48        SEND_VAL                                                 1
         49        DO_ICALL                                         $22     
         50        SEND_VAR_NO_REF_EX                                       $22
         51        DO_FCALL                                      0  $23     
         52        INIT_FCALL_BY_NAME                                       'toInt32'
         53        INIT_FCALL                                               'substr'
         54        SEND_VAR                                                 !0
         55        SEND_VAL                                                 -1
         56        SEND_VAL                                                 1
         57        DO_ICALL                                         $24     
         58        SEND_VAR_NO_REF_EX                                       $24
         59        DO_FCALL                                      0  $25     
         60        MUL                                              ~26     $23, $25
         61        ASSIGN                                                   !4, ~26
   14    62        CONCAT                                           ~28     !2, !3
         63        CONCAT                                           ~29     ~28, !4
         64        ASSIGN                                                   !5, ~29
   16    65        INIT_FCALL                                               'var_dump'
         66        SEND_VAR                                                 !5
         67        DO_ICALL                                                 
   24    68      > RETURN                                                   1

Function toint32:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 13
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m4Vdi
function name:  toInt32
number of ops:  16
compiled vars:  !0 = $value, !1 = $intval
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   RECV                                             !0      
   21     1        INIT_FCALL                                               'hexdec'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $2      
          4        ASSIGN                                                   !1, $2
   22     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !0
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                                 
   23     9      > JMPZ                                                     <true>, ->13
         10    >   SUB                                              ~5      !1, 4294967296
         11        QM_ASSIGN                                        ~6      ~5
         12      > JMP                                                      ->14
         13    >   QM_ASSIGN                                        ~6      !1
         14    > > RETURN                                                   ~6
   24    15*     > RETURN                                                   null

End of function toint32

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.6 ms | 1400 KiB | 21 Q