Skip to content

Latest commit

 

History

History
71 lines (45 loc) · 1.32 KB

README.org

File metadata and controls

71 lines (45 loc) · 1.32 KB

Advent of Code 2020

My solutions for Advent of Code 2020.

Installation

I tried to use Nix to set up local development environments. For each day you can cd into the respective directory and use nix-shell to install all the dependencies you need. I ran into some issues with installing Clojure with Nix so this doesn’t apply for the days when I used that language.

Specific commands to run the programs for each day are specified below.

Solutions

Day 1: SWI Prolog

nix-shell --pure --run "swipl day1.pl"

Day 2: Clojure

  • Clojure: clojure day2.clj
  • Babashka: bb day2.clj

Day 3: Elixir

nix-shell --pure --run "elixir day3.exs"

Day 4: Elixir

nix-shell --pure --run "elixir day4.exs"

Day 5: SWI Prolog

nix-shell --pure --run "swipl day5.pl"

Day 6: Elixir

nix-shell --pure --run "elixir day6.exs"

Day 7: SWI Prolog (and a bit of Python)

nix-shell --pure --run "python3 parse.py && swipl day7.pl"

Day 8: Rust

nix-shell --pure --run "cargo run"

Day 9: SWI Prolog

nix-shell --pure --run "swipl day9.pl"

Day 10: SWI Prolog

nix-shell --pure --run "swipl day10.pl"