Some pieces of unrelated code from my time at uni.