The idea is to use just one function to compute everything. It suffices to do this for bits: bytes consist of bits, and if we can compute bits, we also can compute bytes, and everything made up of bytes. That is, everything.
There are sixteen boolean functions of two arguments. Two of them are special: NOR and NAND. The other fourteen functions can be computed using only either NOR or NAND. We’ll use NOR.
NOR’s truth table is as follows:
===== ========
Input Output
===== ========
A B A NOR B
----- --------
0 0 1
0 1 0
1 0 0
1 1 0
===== ========
https://github.com/yuanxinyu/NOR-CPU