### Question:
HMapID implements MapID, Cloneable, Serializable { public MapID.Entry[] getEntriesSortedByValue() { if (this.size() == 0) return null; MapID.Entry[] entries = new Entry[this.size()]; int i = 0; Entry next = null; int index = 0; while (index < table.length && (next = table[index++]) == null) ; while (next != null) { Entry e = next; next = e.next; if ((next = e.next) == null) { while (index < table.length && (next = table[index++]) == null) ; } entries[i++] = e; } Arrays.sort(entries, new Comparator<MapID.Entry>() { public int compare(MapID.Entry e1, MapID.Entry e2) { if (e1.getValue() > e2.getValue()) { return -1; } else if (e1.getValue() < e2.getValue()) { return 1; } if (e1.getKey() == e2.getKey()) return 0; return e1.getKey() > e2.getKey() ? 1 : -1; } }); return entries; } HMapID(int initialCapacity, float loadFactor);  HMapID(int initialCapacity);  HMapID();  HMapID(MapID m); int size(); boolean isEmpty(); double get(int key); boolean containsKey(int key); double put(int key, double value); void putAll(MapID m); double remove(int key); void clear(); boolean containsValue(double value); Object clone(); Set<Integer> keySet(); Collection<Double> values(); Set<MapID.Entry> entrySet(); String toString(); @Override void plus(MapID m); @Override double dot(MapID m); @Override void increment(int key); @Override void increment(int key, double value); double length(); void normalize(); MapID.Entry[] getEntriesSortedByValue(); MapID.Entry[] getEntriesSortedByValue(int n);  }### Answer:
@Test public void testSortedEntries4() { HMapID m = new HMapID(); MapID.Entry[] e = m.getEntriesSortedByValue(); assertTrue(e == null); }