init and insert functions have been added