finish the data_structure_2 function