Implementing delete [DEL] logic