3v4l.org

run code in 300+ PHP versions simultaneously
<?php $bmi = sprintf("%.2lf", calculateBMI($height, $heightUnit, $weight, $weightUnit)); $text = //"<p> "."<img src = ". //" http://cs.smu.ca/~webbook/cdrom/web08/nature/images/naturelogo.gif ". //" alt = 'Nature's Source Logo' />"."</p>". "<h1>BMI Report</h1>". "<h3>Your height: ".$height." ".$heightUnit."<br />". "Your weight: ".$weight." ".$weightUnit."<br />". "Your BMI: ".$bmi."</h3>"; if ($bmi < 18.5) $text .= "<h2>Your BMI suggests that you are underweight.</h2>"; else if ($bmi < 25) $text .= "<h2>Your BMI suggests that you have a reasonable weight.</h2>"; else if ($bmi < 29) $text .= "<h2>Your BMI suggests that you are overweight.</h2>"; else $text .= "<h2>Your BMI suggests that you may be obese.</h2>"; return $text;
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 26, Position 2 = 28
Branch analysis from position: 26
1 jumps found. (Code = 42) Position 1 = 37
Branch analysis from position: 37
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 28
2 jumps found. (Code = 43) Position 1 = 30, Position 2 = 32
Branch analysis from position: 30
1 jumps found. (Code = 42) Position 1 = 37
Branch analysis from position: 37
Branch analysis from position: 32
2 jumps found. (Code = 43) Position 1 = 34, Position 2 = 36
Branch analysis from position: 34
1 jumps found. (Code = 42) Position 1 = 37
Branch analysis from position: 37
Branch analysis from position: 36
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fQl5A
function name:  (null)
number of ops:  39
compiled vars:  !0 = $bmi, !1 = $height, !2 = $heightUnit, !3 = $weight, !4 = $weightUnit, !5 = $text
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'sprintf'
          1        SEND_VAL                                                 '%25.2lf'
          2        INIT_FCALL_BY_NAME                                       'calculateBMI'
          3        SEND_VAR_EX                                              !1
          4        SEND_VAR_EX                                              !2
          5        SEND_VAR_EX                                              !3
          6        SEND_VAR_EX                                              !4
          7        DO_FCALL                                      0  $6      
          8        SEND_VAR                                                 $6
          9        DO_ICALL                                         $7      
         10        ASSIGN                                                   !0, $7
    7    11        CONCAT                                           ~9      '%3Ch1%3EBMI+Report%3C%2Fh1%3E%3Ch3%3EYour+height%3A+', !1
         12        CONCAT                                           ~10     ~9, '+'
         13        CONCAT                                           ~11     ~10, !2
         14        CONCAT                                           ~12     ~11, '%3Cbr+%2F%3E'
    8    15        CONCAT                                           ~13     ~12, 'Your+weight%3A+'
         16        CONCAT                                           ~14     ~13, !3
         17        CONCAT                                           ~15     ~14, '+'
         18        CONCAT                                           ~16     ~15, !4
         19        CONCAT                                           ~17     ~16, '%3Cbr+%2F%3E'
    9    20        CONCAT                                           ~18     ~17, 'Your+BMI%3A+'
         21        CONCAT                                           ~19     ~18, !0
         22        CONCAT                                           ~20     ~19, '%3C%2Fh3%3E'
    3    23        ASSIGN                                                   !5, ~20
   10    24        IS_SMALLER                                               !0, 18.5
         25      > JMPZ                                                     ~22, ->28
   11    26    >   ASSIGN_OP                                     8          !5, '%3Ch2%3EYour+BMI+suggests+that+you+are+underweight.%3C%2Fh2%3E'
         27      > JMP                                                      ->37
   12    28    >   IS_SMALLER                                               !0, 25
         29      > JMPZ                                                     ~24, ->32
   13    30    >   ASSIGN_OP                                     8          !5, '%3Ch2%3EYour+BMI+suggests+that+you+have+a+reasonable+weight.%3C%2Fh2%3E'
         31      > JMP                                                      ->37
   14    32    >   IS_SMALLER                                               !0, 29
         33      > JMPZ                                                     ~26, ->36
   15    34    >   ASSIGN_OP                                     8          !5, '%3Ch2%3EYour+BMI+suggests+that+you+are+overweight.%3C%2Fh2%3E'
         35      > JMP                                                      ->37
   17    36    >   ASSIGN_OP                                     8          !5, '%3Ch2%3EYour+BMI+suggests+that+you+may+be+obese.%3C%2Fh2%3E'
   18    37    > > RETURN                                                   !5
         38*     > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
196.26 ms | 1400 KiB | 15 Q