3v4l.org

run code in 300+ PHP versions simultaneously
<?php function getGrade($score) { echo chr(intdiv($score, 10) * -1 + 10 + 64); } echo getGrade(85);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/MM01W
function name:  (null)
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   INIT_FCALL                                               'getgrade'
          1        SEND_VAL                                                 85
          2        DO_FCALL                                      0  $0      
          3        ECHO                                                     $0
          4      > RETURN                                                   1

Function getgrade:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/MM01W
function name:  getGrade
number of ops:  13
compiled vars:  !0 = $score
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        INIT_FCALL                                               'chr'
          2        INIT_FCALL                                               'intdiv'
          3        SEND_VAR                                                 !0
          4        SEND_VAL                                                 10
          5        DO_ICALL                                         $1      
          6        MUL                                              ~2      $1, -1
          7        ADD                                              ~3      ~2, 10
          8        ADD                                              ~4      ~3, 64
          9        SEND_VAL                                                 ~4
         10        DO_ICALL                                         $5      
         11        ECHO                                                     $5
    5    12      > RETURN                                                   null

End of function getgrade

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.95 ms | 1003 KiB | 16 Q