int foo(int x) { return (x+3); } int bar (int x) { return (x + (rand() % 4)); }
Input | Output | |
---|---|---|
a | b | a AND b |
0 | 0 | 0 |
0 | 1 | 0 |
1 | 0 | 0 |
1 | 1 | 1 |
Input | Output | |||
---|---|---|---|---|
i0 | i1 | i2 | i3 | o4 |
0 | 0 | 0 | 0 | 0 |
0 | 0 | 0 | 1 | 1 |
0 | 0 | 1 | 0 | 1 |
0 | 0 | 1 | 1 | 0 |
0 | 1 | 0 | 0 | 1 |
0 | 1 | 0 | 1 | 0 |
0 | 1 | 1 | 0 | 0 |
0 | 1 | 1 | 1 | 1 |
1 | 0 | 0 | 0 | 1 |
1 | 0 | 0 | 1 | 0 |
1 | 0 | 1 | 0 | 0 |
1 | 0 | 1 | 1 | 1 |
1 | 1 | 0 | 0 | 0 |
1 | 1 | 0 | 1 | 1 |
1 | 1 | 1 | 0 | 1 |
1 | 1 | 1 | 1 | 0 |
Input | Output | |
---|---|---|
i0 | i1 | o2 |
0 | 0 | 0 |
0 | 1 | 1 |
1 | 0 | 1 |
1 | 1 | 0 |
Operation Name | Symbol | Table | Boolean Expression | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
and | ![]() |
| o=i0*i1 | ||||||||||||||||||
or | ![]() |
| o=i0+i1 | ||||||||||||||||||
not | ![]() |
| ![]() | ||||||||||||||||||
xor | ![]() |
| ![]() |
Input | Output | ||
---|---|---|---|
i0 | i1 | s | c |
0 | 0 | 0 | 0 |
0 | 1 | 1 | 0 |
1 | 0 | 1 | 0 |
1 | 1 | 0 | 1 |