Code challenge with simple datastructures