In compact.rs of week2 day1 commit. You use HashSet to update state.l0_sstables in function force_full_compaction:
let mut l0_sstables_map = l0_sstables.iter().copied().collect::<HashSet<_>>();
state.l0_sstables = state
.l0_sstables
.iter()
.filter(|x| !l0_sstables_map.remove(x))
.copied()
.collect::<Vec<_>>();
Actually, Vec::resize can be used to update state.l0_sstables. Because we always choose consecutive sst_ids from l0_sstables array:
snapshot
.l0_sstables
.resize(snapshot.l0_sstables.len() - l0_sstables.len(), 0);