Add ability to delete task from array. Fix array index error.