Skip to content

Latest commit

 

History

History
22 lines (15 loc) · 940 Bytes

README.md

File metadata and controls

22 lines (15 loc) · 940 Bytes

Advent of Code in Red

This is a small collection of solutions to Advent of Code problems, and a problem input downloader.

I mostly use Advent of Code to experiment with different ways of solving the problems, and tend to not get very far. I might have some weird solutions.

To use the input downloader, copy read-input.red to your workspace, and save your browser session cookie to session-cookie.txt. image

Then put something like this at the top of your script:

#include %read-input.red

year: 2021
day: 1
problem-input: load read-input year day
; or maybe
problem-input-lines: read-lines get-input year day

It plays nice with the site, and only downloads the input a single time. After that, it will load from the cached version in the local directory.