title: Java- Why the method argument treats the float value as double value?
body: <p>I've defined a method with one parameter of type float shown below:</p>
  
  <pre><code>public float getValue(float value){
  
      return value;
  }
  </code></pre>
  
  <p>When I call this method by passing float value say <strong>10.1201</strong> shown below:</p>
  
  <pre><code>float value =  methodReturnTest.getValue(10.1201);
  </code></pre>
  
  <p>My IDE says to cast the argument to float. I tried searching but couldn't get the appropriate answer. so posting it.
  Please explain . </p>
  
  <p>Thanks.</p>