Updated del function and solved