inst/run-day06.R

library(adventofcode20)
x <- readLines("./inst/input06.txt")

p1 <- x %>% find_unique_questions() %>% lengths() %>% sum()
p2 <- x %>% find_shared_questions() %>% lengths() %>% sum()

stopifnot(p1 == aoc20_solutions$day06a)
stopifnot(p2 == aoc20_solutions$day06b)
tjmahr/adventofcode20 documentation built on Dec. 31, 2020, 8:39 a.m.