Buddy, that you have taken the right idea and approach the solution of the problem, but there is simply not enough small edge (information) to solve the problem correctly.
I would like to give a little hint, which, I believe, can help and fix the problem and understand the basics really very well.
If you look at the documentation (or source code) hashCodefor Stringand variables Double, it states
LINE
- . - String s [0] * 31 ^ (n-1) + s [1] * 31 ^ (n-2) +... + s [n-1] int , s [i] - i- , n - , ^ . (- .)
: - .
DOUBLE
- . , , doubleToLongBits(double), , . , - :
(int)(v^(v>>>32))
v : long v = Double.doubleToLongBits(this.doubleValue());
: - .
, hashCode() , , int .
, .
, HashMap<Integer,List<String>>, Integer hashCode , , List<String> - , String coutrycode + + .
, List<String> hashCode() , List String.