implement some basic data structures