public void Test_Contains() { IndexedMinPQ <Int32> pq = new IndexedMinPQ <Int32>(5); for (int i = 1; i < 6; i++) { pq.Add(i, i); } Assert.True(pq.Contains(4)); }
public void Test_Delete() { IndexedMinPQ <Int32> pq = new IndexedMinPQ <Int32>(5); for (int i = 1; i < 6; i++) { pq.Add(i, i); } pq.Delete(4); Assert.False(pq.Contains(4)); }