title: Double is not converting to an int
body: <p>This code I have written to convert <code>double</code> into <code>int</code> getting an exception.</p>
  
  <pre><code>Exception in thread "main" java.lang.Error: Unresolved compilation problem: 
  Cannot cast from Double to int
  </code></pre>
  
  <p>This is my code</p>
  
  <pre><code>Double d = 10.9;    
  int i = (int)(d);
  </code></pre>