Programming

Advent of Code F# – Day 14

ps. look out for all my other solutions for Advent of Code challenges here.   Day 14 See details of the challenge here. Today’s challenge is very similar to that of Day 5, but the requirements for a valid hash value is different this time. As before, we’ll start by defining a hash function that will accept a string and return …

Advent of Code F# – Day 14 Read More »

Advent of Code F# – Day 13

ps. look out for all my other solutions for Advent of Code challenges here.   Day 13 See details of the challenge here. Today’s challenge involves solving two separate problems: counting set bits in an integer level order tree traversal For the first problem, I recommend reading through this blog post which covers several approaches and optimizations for this …

Advent of Code F# – Day 13 Read More »

Implementing a BST in F#

Binary Search Trees (BST) seem to be a hot topic in technical interviews. So, in order to help me prepare for all these grilling technical tests, I thought I’d give it a crack at implementing insertion, deletion and verification logic since I’ve already done both breath-first and depth-first traversals.   Verification Starting with something nice and …

Implementing a BST in F# Read More »

Advent of Code F# – Day 9

ps. look out for all my other solutions for Advent of Code challenges here.   Day 9 See details of the challenge here. The input for today’s challenge is a very long string like this: (6×9)JUORKH(10×13)LNWIKDMACM(126×14)(21×8)QLKUJNVVZIQGGFCJZMPHK(2×1)ZH(59×3)(38×14)KELEPIDYLCGJUBCXACRSOCEZYXLO… First, let’s see how we’re gonna parse this input. The approach I went with is to recursively split the input …

Advent of Code F# – Day 9 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