This commit is contained in:
Rose Apollo 2024-11-30 22:13:38 +00:00
parent e649b1a3bd
commit 613bf38d91
2 changed files with 4 additions and 2 deletions

View File

@ -7,9 +7,9 @@
int main(int argc, char** argv)
{
int x, y;
char d[] = "(D^B)v(B^-C)v(B^(-C^-D))v(A^C^D)v(-C^D^-A^-B)";
char d[] = "(-(AvB)v-(A^B))^((-A^B)v((AvB)^(-Bv-A)))";
bool* c = logic_karn_run(d, 4, &x, &y);
bool* c = logic_karn_run(d, 2, &x, &y);
logic_karn_render(c, x, y);
return 0;

View File

@ -54,6 +54,8 @@ void logic_karn_render(bool* karn, int x, int y)
printf("|\n");
}
printf("\n"); // just nicely end it
}
bool* logic_karn_run(char* equ, int args, int *x, int *y)