title: use case for Double as HashMap Keys
body: <p>I am just going through my notes where I have <code>Doubles</code> as <code>HashMap</code> keys are bad that I vaguely remember using it for some online coding platform.</p>
  
  <p>Are there any use cases and alternatives in dealing with <code>Double</code> as Keys which you have dealt with in real world or interviews or coding problems?</p>
  
  <p>I was thinking of the following, in case of an interview I can argue to use this and make my argument this is the best we can do.?</p>
  
  <pre><code>MyDouble(){
     private final double original;
     private final long value;
  
     public MyDouble(double original) {
        this.original = original;
        this.value = Double.doubleToLongBits(original);
     }
  }
  </code></pre>