computer science

A data model exercise in two languages, part 2: F#

May 22, 2017 · f# computer science c#

Introduction In the previous post I took a look at a data modelling exercise in C#, I designed a data model to represent a card in the standard 52-card deck. We saw some of the problems we face when designing »

A data model exercise in two languages, part 1: C#

May 4, 2017 · c# f# computer science

Introduction When I'm learning a new programming language, I usually like to do some coding exercises to get familiar with the various language features, and to get used to the syntax. Many of these exercises—or katas—are about implementing »

Back to basics: Dictionary part 4, custom GetHashCode

October 25, 2015 · c# .net basics computer science

General guidelines This is the last part in the series about the Dictionary class and the GetHashCode method. In this post we'll take a look at what to look out for when implementing a custom GetHashCode method. In the previous »

Back to basics: Dictionary part 3, built-in GetHashCode

August 29, 2015 · c# .net basics computer science

In the previous two posts we looked at the basic concepts behind the hash map data structure, and checked out how it is implemented in the Dictionary class of the .NET Framework. Today we'll take a look at a very »

Back to basics: Dictionary part 2, .NET implementation

August 15, 2015 · c# .net basics computer science

Introduction Last time we saw an overview about the basic concepts behind a hash map. In this post we will take a look at the .NET Dictionary class, and see what type of hash map it is and how the »

Back to basics: Dictionary part 1, hash tables

July 25, 2015 · c# .net basics computer science

Recently I came across a situation in which I should have known the details about how a .NET Dictionary (and hashmaps in general) worked under the hood. I realized that my knowledge about this topic was a bit rusty, so »