Basic data structures implementations in c+