mirror of
https://github.com/Kaehvaman/OAIP.git
synced 2025-01-18 16:49:11 +04:00
17 lines
314 B
C
17 lines
314 B
C
#include <stdio.h>
|
|
#include <iso646.h>
|
|
|
|
int f(int A, int B) {
|
|
return (A and B) == (((not B) <= (not A)) xor A);
|
|
}
|
|
|
|
int main() {
|
|
printf_s("A B f\n");
|
|
for (int A = 0; A <= 1; A++) {
|
|
for (int B = 0; B <= 1; B++) {
|
|
printf_s("%d %d %d\n", A, B, f(A, B));
|
|
}
|
|
}
|
|
return 0;
|
|
}
|