import java.util.*;

public class MapOperations { 

    public static TreeMap<String, String> reverseMap( TreeMap<String, String> forward ) {
        TreeMap<String,String> reverse = new TreeMap<String,String>();
        for( String key : forward.keySet() ) {
            String value = forward.get(key);
            reverse.put(value,key);
        }
        return reverse;
    }

    public static TreeMap<Double, String> reverseDistanceMap( TreeMap<String, Double> forward ) {
        TreeMap<Double,String> reverse = new TreeMap<Double,String>();
        for( String key : forward.keySet() ) {
            Double value = forward.get(key);
            reverse.put(value,key);
        }
        return reverse;
    }

}

@@ -18,38 +18,168 @@
 *;%0A%0A
-public class MapOperations %7B %0A
+/** MapOperations:%0A *%0A * This class defines several static methods for reversing maps.%0A */%0Apublic class MapOperations %7B %0A%0A    /** Reverse a String-String map */
 %0A   
@@ -505,16 +505,55 @@
 %0A    %7D%0A%0A
+    /** Reverse a String-Double map */%0A
     publ

Update MapOperations.java