3v4l.org

run code in 300+ PHP versions simultaneously
<?php $hasil = 52.5; $kecewa = array(0,40,65); $biasa = array(40,65,80); $puas = array(65,80,100); $kb = array_intersect($kecewa, $biasa); print_r($kb); if ( $hasil <= $kb ) { // hitung nilai kecewa pake rumus fuzzy logic $muKecewa = ($kb[2] - $hasil) / ($kb[2] - $kb[1]); //output : 52,5 $muBiasa = ($muKecewa <= 1) ? '0' : '0.5'; // output: bool(true) echo $muKecewa; echo "<br />"; echo $muBiasa; } else { echo "false"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 14, Position 2 = 31
Branch analysis from position: 14
2 jumps found. (Code = 43) Position 1 = 23, Position 2 = 25
Branch analysis from position: 23
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
1 jumps found. (Code = 42) Position 1 = 32
Branch analysis from position: 32
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 25
1 jumps found. (Code = 42) Position 1 = 32
Branch analysis from position: 32
Branch analysis from position: 31
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/B7auJ
function name:  (null)
number of ops:  33
compiled vars:  !0 = $hasil, !1 = $kecewa, !2 = $biasa, !3 = $puas, !4 = $kb, !5 = $muKecewa, !6 = $muBiasa
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 52.5
    3     1        ASSIGN                                                   !1, <array>
    4     2        ASSIGN                                                   !2, <array>
    5     3        ASSIGN                                                   !3, <array>
    6     4        INIT_FCALL                                               'array_intersect'
          5        SEND_VAR                                                 !1
          6        SEND_VAR                                                 !2
          7        DO_ICALL                                         $11     
          8        ASSIGN                                                   !4, $11
    7     9        INIT_FCALL                                               'print_r'
         10        SEND_VAR                                                 !4
         11        DO_ICALL                                                 
    9    12        IS_SMALLER_OR_EQUAL                                      !0, !4
         13      > JMPZ                                                     ~14, ->31
   12    14    >   FETCH_DIM_R                                      ~15     !4, 2
         15        SUB                                              ~16     ~15, !0
         16        FETCH_DIM_R                                      ~17     !4, 2
         17        FETCH_DIM_R                                      ~18     !4, 1
         18        SUB                                              ~19     ~17, ~18
         19        DIV                                              ~20     ~16, ~19
         20        ASSIGN                                                   !5, ~20
   13    21        IS_SMALLER_OR_EQUAL                                      !5, 1
         22      > JMPZ                                                     ~22, ->25
         23    >   QM_ASSIGN                                        ~23     '0'
         24      > JMP                                                      ->26
         25    >   QM_ASSIGN                                        ~23     '0.5'
         26    >   ASSIGN                                                   !6, ~23
   15    27        ECHO                                                     !5
   16    28        ECHO                                                     '%3Cbr+%2F%3E'
   17    29        ECHO                                                     !6
         30      > JMP                                                      ->32
   22    31    >   ECHO                                                     'false'
   23    32    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.81 ms | 937 KiB | 18 Q