title: Java instantiate Short object in Java
body: <p>I was wondering why we can do: </p>
  
  <pre><code>Long l = 2L;
  Float f = 2f;
  Double d = 2d;
  </code></pre>
  
  <p>or even </p>
  
  <pre><code>Double d = new Double(2);
  </code></pre>
  
  <p>and not</p>
  
  <pre><code>Short s = 2s; //or whatever letter it could be
  </code></pre>
  
  <p>nor</p>
  
  <pre><code>Short s = new Short(2); //I know in this case 2 is an int but couldn't it be casted internally or something?
  </code></pre>
  
  <p>Why do we need to take the constructors either with a String or a short.</p>