more tweaks about bitwise oerations - this was a tricky one - and the first that I wrote