Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Advent of Code 2015

Spoiler Warning: If you want to solve the challenges by yourself, don't read the code.

This directory contains the code I used to solve the challenges from Advent of Code 2015.

I used Haskell for most of the riddles. Sometimes I conceived a Ruby solution, if there was a neat application for regexes or OOP. For algorithms which profit from random access or are just easily faster imperatively, I used C.

Contents

The following table lists the available solutions by day and language. I also added a short summary for each day. I marked the solutions which I consider especially valuable or pretty with a star (☆).

Day C Haskell Ruby Description
01 x x x Parenthesis counting
02 x Wrapping paper
03 x Routes delivering to houses
04 MD5 mining
05 x x Nice string text processing
06 x x Light installation
07 x Bitwise signal wiring
08 x x String escaping
09 TSP
10 Look-and-Say Numbers / RLE
11 x Base26 increment, password rules
12 x JSON number sums
13 x Seating happiness
14 x Racing Reindeer
15 x x Optimize cookie receipt
16 x Aunt Detective
17 x x Eggnog container subset sums
18 x GoL with Lights
19 x Medicine with molecules and grammars
20 x Elves delivering by factor sums
21 x Bossfight with items
22 x Bossfight with Wizard and mana
23 x RAM Computer Simulation
24 x Optimizing partitions
25 x Cantor pairing and residue field
Σ 6 23 5

Takeaways

In addition to having a lot of fun solving the puzzles, I also applied some interesting programming techniques for the first time in C or Ruby:

Also I learned and applied these new concepts about Haskell:

Completion

I finally completed all the puzzles:

image

Other solutions

I enjoy looking at how other coder solved the riddles. This year I followed (A-Z):