summaryrefslogtreecommitdiff
path: root/02.c
diff options
context:
space:
mode:
authorVincent Douillet <vincent@vdouillet.fr>2021-12-05 22:53:32 +0100
committerVincent Douillet <vincent@vdouillet.fr>2021-12-05 22:53:32 +0100
commit8a8417207729cb92ae4f3038a3a8bd5e6a0c0ce7 (patch)
treea1366131e356ffadfa081c1561c968a2570a9843 /02.c
parent4c42453d856053bb49affef7c165397e5c16d9eb (diff)
add expected results to previous days
Diffstat (limited to '02.c')
-rw-r--r--02.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/02.c b/02.c
index 30af77f..9814501 100644
--- a/02.c
+++ b/02.c
@@ -4,6 +4,8 @@
#include "input.h"
#define INPUT "input/02.txt"
+#define EXPECTED1 2272262L
+#define EXPECTED2 2134882034L
enum direction { forward, up, down };
@@ -47,7 +49,7 @@ void part1(struct input_str* input) {
continue;
}
}
- printf("%ld\n", forwardDst * downDst);
+ CHECK(forwardDst * downDst, EXPECTED1)
}
void part2(struct input_str* input) {
@@ -70,7 +72,7 @@ void part2(struct input_str* input) {
continue;
}
}
- printf("%ld\n", forwardDst * downDst);
+ CHECK(forwardDst * downDst, EXPECTED2)
}
int main() {