Working on delete class algorithm