Precedence and bitmask operations Precedence and bitmask operations php php

Precedence and bitmask operations


You are actually doing this:

var_dump(0b10 & (0b01 == 0));var_dump(0b10 & (0b01 != 0));

Try:

var_dump((0b10 & 0b01) == 0);var_dump((0b10 & 0b01) != 0);