title: Why does the division of two integers return 0.0 in Java?
body: <pre><code>int totalOptCount = 500;
  int totalRespCount=1500; 
  float percentage =(float)(totalOptCount/totalRespCount);
  </code></pre>
  
  <p>Why does this always return value 0.0? Also I want to format this into 00.00 format and convert into string?</p>