Overview
| Comment: | fixed possible bug (2) |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA3-256: |
afa0bfe340a3eb45ce5876e46a7227d2 |
| User & Date: | nnz on 2024-12-07 14:39:40.892 |
| Other Links: | manifest | tags |
Context
|
2024-12-07
| ||
| 14:41 | fixed possible bug (3) check-in: 4ad4c64403 user: nnz tags: trunk | |
| 14:39 | fixed possible bug (2) check-in: afa0bfe340 user: nnz tags: trunk | |
| 14:37 | fixed possible bug check-in: c6ad316f4d user: nnz tags: trunk | |
Changes
Modified aoc2024.c
from [1242bf1894]
to [7cc4fb360f].
| ︙ | ︙ | |||
37 38 39 40 41 42 43 |
a[1] = tmp;
if (!pplus && !pmult) {
a[1] = concat(a[0], tmp);
pconcat = operatorsrequired(v, a+1, n-1, 3);
a[1] = tmp;
}
if (pconcat) return 3;
| | | | 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
a[1] = tmp;
if (!pplus && !pmult) {
a[1] = concat(a[0], tmp);
pconcat = operatorsrequired(v, a+1, n-1, 3);
a[1] = tmp;
}
if (pconcat) return 3;
if (pmult) return pmult;
if (pplus) return pplus;
return 0;
}
void aoc202407(char *data, size_t len) {
(void)len; // unused argument
unsigned long long calibrationtotal = 0, calibration3total = 0;
char *line = strtok(data, "\n");
|
| ︙ | ︙ |