/AoC2020

My solutions for https://adventofcode.com/2022

Primary LanguagePrologGNU General Public License v3.0GPL-3.0

Advent of Code

This repository contains my solutions to Advent of Code 2020 (https://adventofcode.com/). I will try to keep a naming scheme like [day]_[no].prolog so e.g. 1_1.prolog will be the first riddle of the first day. Please be fair and do not look at solutions to riddles you have not solved yourself.

Execution

You can either load and execute each riddle individually in prolog or just run solveAll.sh which will solve all riddles in the repository in ascending order.

Either way you will need a prolog interpreter (e.g. swi-prolog).

Choice of Programming Language

I will try to solve all of the riddles in Prolog, although I have no experience in Prolog at all. I only had one introduction into Prolog ~15 years ago, so probably anybody who has experience in Prolog will probably bang his head against the wall when he sees my solutions. ;)

Nevertheless I choose Prolog because I like the idea of describing the problem rather than inventing an algorithm that solves the problem and I think it could be used quite efficiently to solve such riddle.