3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.15 ms | 1392 KiB | 17 Q