added methods to remove Array and Map elements