some datastructure problems