3v4l.org

run code in 300+ PHP versions simultaneously
<?php $img = ["-1" => "/images/image2.jpg", "0" => "/images/image3.jpg", "1" => "/images/image1.jmp"]; $number = 0; Echo ($number == 0 ? $img[$number] : $img[$number/abs($number)]);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 7
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 13
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JstZl
function name:  (null)
number of ops:  15
compiled vars:  !0 = $img, !1 = $number
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    7     1        ASSIGN                                                   !1, 0
    9     2        IS_EQUAL                                                 !1, 0
          3      > JMPZ                                                     ~4, ->7
          4    >   FETCH_DIM_R                                      ~5      !0, !1
          5        QM_ASSIGN                                        ~6      ~5
          6      > JMP                                                      ->13
          7    >   INIT_FCALL                                               'abs'
          8        SEND_VAR                                                 !1
          9        DO_ICALL                                         $7      
         10        DIV                                              ~8      !1, $7
         11        FETCH_DIM_R                                      ~9      !0, ~8
         12        QM_ASSIGN                                        ~6      ~9
         13    >   ECHO                                                     ~6
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.58 ms | 1398 KiB | 15 Q