complete 19532 with boj step12 rework & setting zeta_C with clang-18

This commit is contained in:
2024-04-04 21:14:06 +09:00
parent dae701221d
commit 1399c832c7
2 changed files with 22 additions and 0 deletions

18
zeta_C/completed/19532.c Normal file
View File

@@ -0,0 +1,18 @@
#include <stdio.h>
#include <stdlib.h>
int main() {
int a, b, c, d, e, f;
scanf("%d %d %d %d %d %d", &a, &b, &c, &d, &e, &f);
for (int x = -999; x <= 999; x++) {
for (int y = -999; y <= 999; y++) {
if (a * x + b * y == c && d * x + e * y == f) {
printf("%d %d\n", x, y);
goto finish;
}
}
}
finish:
return 0;
}

4
zeta_C/run.sh Normal file
View File

@@ -0,0 +1,4 @@
#!/bin/bash
if [ -z "$*" ]; then echo "No args"; exit 0; fi
clang-18 -std=c17 $1
./a.out < stdin.txt