Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Easy way to remember it: Never both together (NBT)


It’s easier to remember it as a bit inverter, or as boolean “not equal”, IMO. And “exclusive or” pretty much already spells out what it does.

Regarding the first one I might be biased by learning XOR from https://www.chiark.greenend.org.uk/~sgtatham/quasiblog/xor/#..., however.


Red pill VS Blue pill, that's how I use to memorise it. You must choose one.

Now, it just means 'not equal', 'different', 'not same' etc.


I use this to remember what it does and also like thinking of XOR as an operation you can apply with a mask to flip bits (the linked article mentions this).


Sounds like NAND.


that would just be "not both"




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: