3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array( array(5,5), array(4,3), array(4,0) ); // ______ - // | _____ mind. 1 Position komplett offen // || ____ Position mit Teilmengen geliefert // ||| ___ alles komplett // |||| $bitmask = bindec('0001'); printf("%04b\n", $bitmask); foreach ($arr as $w) { if ($w[0] == $w[1]) $bitmask |= bindec('0010'); printf("%04b\n", $bitmask); if ($w[1] == 0) $bitmask &= ~bindec('0101'); printf("%04b\n", $bitmask); if ($w[1] > 0) $bitmask &= ~bindec('0001'); printf("%04b\n", $bitmask); echo "=====\n"; } ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 10, Position 2 = 49
Branch analysis from position: 10
2 jumps found. (Code = 78) Position 1 = 11, Position 2 = 49
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 19
Branch analysis from position: 15
2 jumps found. (Code = 43) Position 1 = 26, Position 2 = 31
Branch analysis from position: 26
2 jumps found. (Code = 43) Position 1 = 38, Position 2 = 43
Branch analysis from position: 38
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
Branch analysis from position: 43
Branch analysis from position: 31
Branch analysis from position: 19
Branch analysis from position: 49
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 49
filename:       /in/ru2YN
function name:  (null)
number of ops:  51
compiled vars:  !0 = $arr, !1 = $bitmask, !2 = $w
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   14     1        INIT_FCALL                                               'bindec'
          2        SEND_VAL                                                 '0001'
          3        DO_ICALL                                         $4      
          4        ASSIGN                                                   !1, $4
   15     5        INIT_FCALL                                               'printf'
          6        SEND_VAL                                                 '%2504b%0A'
          7        SEND_VAR                                                 !1
          8        DO_ICALL                                                 
   17     9      > FE_RESET_R                                       $7      !0, ->49
         10    > > FE_FETCH_R                                               $7, !2, ->49
   18    11    >   FETCH_DIM_R                                      ~8      !2, 0
         12        FETCH_DIM_R                                      ~9      !2, 1
         13        IS_EQUAL                                                 ~8, ~9
         14      > JMPZ                                                     ~10, ->19
   19    15    >   INIT_FCALL                                               'bindec'
         16        SEND_VAL                                                 '0010'
         17        DO_ICALL                                         $11     
         18        ASSIGN_OP                                     9          !1, $11
   20    19    >   INIT_FCALL                                               'printf'
         20        SEND_VAL                                                 '%2504b%0A'
         21        SEND_VAR                                                 !1
         22        DO_ICALL                                                 
   22    23        FETCH_DIM_R                                      ~14     !2, 1
         24        IS_EQUAL                                                 ~14, 0
         25      > JMPZ                                                     ~15, ->31
   23    26    >   INIT_FCALL                                               'bindec'
         27        SEND_VAL                                                 '0101'
         28        DO_ICALL                                         $16     
         29        BW_NOT                                           ~17     $16
         30        ASSIGN_OP                                    10          !1, ~17
   24    31    >   INIT_FCALL                                               'printf'
         32        SEND_VAL                                                 '%2504b%0A'
         33        SEND_VAR                                                 !1
         34        DO_ICALL                                                 
   26    35        FETCH_DIM_R                                      ~20     !2, 1
         36        IS_SMALLER                                               0, ~20
         37      > JMPZ                                                     ~21, ->43
   27    38    >   INIT_FCALL                                               'bindec'
         39        SEND_VAL                                                 '0001'
         40        DO_ICALL                                         $22     
         41        BW_NOT                                           ~23     $22
         42        ASSIGN_OP                                    10          !1, ~23
   28    43    >   INIT_FCALL                                               'printf'
         44        SEND_VAL                                                 '%2504b%0A'
         45        SEND_VAR                                                 !1
         46        DO_ICALL                                                 
   30    47        ECHO                                                     '%3D%3D%3D%3D%3D%0A'
   17    48      > JMP                                                      ->10
         49    >   FE_FREE                                                  $7
   32    50      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.95 ms | 1400 KiB | 17 Q