That is not sorting. That is the opposite of sorting.
Maps do not support a recognisable ordering as a default. There are two kinds of Map which do,
The composite Map (well, I call it that), which contains both a Map and a List, whose Iterator returns K‑V pairs in order of first insertion.The Sorted Map, whose Iterator returns pairs in ascending order of the value of the “K” (I think). A Map which iterates A‑B‑C‑D‑E sounds like a sorted Map.I am not aware of any way to un‑sort a Map.
You can try putting all the elements into an ordinary Map (e.g. HashMap), but you will probably get things sorted by hash code in reverse bit order, so youmight still get A‑B‑C‑D‑E.
You can try loading all the pairs into a List and using the methods of the Collections class to randomise the order of that List. Then add all the elements back into a combined Map and List.