Advent of Code 2021 in Kotlin - Day 1

Advent of Code seems to be very well put together, but I’ve never had a go before. I’ve also been meaning to learn a bit of Kotlin, so I figured I’ll put the two together. At least for one day, no promises on doing all 25. Part 1 The first problem is here. We’re given a list of depth measurements and need to work out how many measurements increase from the day before....

December 2, 2021 · 3 min

Insertion Sort

This implementation is pretty much straight out of the book and we’re required to use the Copy trait as a result, limiting T a great deal. ...

June 7, 2021 · 1 min

Longest Substring Without Repeating Characters in Rust

Given a string, find the length of the longest substring without repeating characters. ...

October 26, 2020 · 2 min

Two Sum in Rust

What a great example of an interview question; there are a few levels of difficulty making the problem accessible to many, a fairly obvious naive O(n2) approach with an oportunity for optimisation, and the curious will find that you can do it in O(n) as well. If I ever run another tech interview training course I’ll probably break apart and analyse this problem with the class. It is, however, quite easy and not ideal for an actual interview....

October 25, 2020 · 4 min

AsyncArrow - The Talk

In January 2017 I spoke at NDC London about async arrows. The video is below. Enjoy!

June 9, 2018 · 1 min