AdventOfCode

Advent of Code F# – Day 5

ps. look out for all my other solutions for Advent of Code challenges here.   Day 5 See details of the challenge here. Let’s start by adding a hash function that’ll take an input string and return the hexdecimal representation of its MD5 hash. From there, we can create an infinite sequence of hash values generated …

Advent of Code F# – Day 5 Read More »

Advent of Code F# – Day 4

ps. look out for all my other solutions for Advent of Code challenges here.   Day 4 See details of the challenge here. The input for today’s challenge looks something like this: bkwzkqsxq-tovvilokx-nozvyiwoxd-172[fstek] wifilzof-wbiwifuny-yhachyylcha-526[qrazx] jvyyvzpcl-jhukf-shivyhavyf-487[zhtsi] kwvacumz-ozilm-kivlg-kwvbiqvumvb-694[gknyw] mvhkvbdib-kmjezxodgz-mvwwdo-omvdidib-837[dmvbi] nzydfxpc-rclop-qwzhpc-lnbftdtetzy-171[cptzd] vhehkyne-unggr-inkvatlbgz-813[gnehk] tcorcikpi-hnqygt-octmgvkpi-570[nzewo] xmtjbzidx-wvnfzo-jkzmvodjin-447[uyzlp] willimcpy-mwupyhayl-bohn-mufym-734[stjoc] sbejpbdujwf-cvooz-xpsltipq-961[azfnd] … So our first task is to turn these into a more usable …

Advent of Code F# – Day 4 Read More »

Advent of Code F# – Day 3

ps. look out for all my other solutions for Advent of Code challenges here.   Day 3 See details of the challenge here. First, let’s capture the input for today’s challenge in a text file, say Day03Input.txt. Then, let’s create a module to capture the common steps between both parts of the challenge. There’s really not …

Advent of Code F# – Day 3 Read More »

Advent of Code F# – Day 2

ps. look out for all my other solutions for Advent of Code challenges here.   Day 2 See details of the challenge here. Let’s start by capturing the model and input data in a module. Since I’m armed with the hindsight of having seen both parts of today’s challenge I’ve refactored the common logic into a solve function: there’s …

Advent of Code F# – Day 2 Read More »

Advent of Code F# – Day 25

The source code for this post is available here and you can click here to see my solutions for the other Advent of Code challenges. Description for today’s challenge is here.   It’s the last day of the advent calendar, and today’s challenge appears difficult at first but mostly because of the grid system it imposes …

Advent of Code F# – Day 25 Read More »

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close