title: Assigning a value to long data type in java - defaulting to int
body: <pre><code>long val = 5000000000;
  </code></pre>
  <p>The error during this assignment is:</p>
  <blockquote>
  <p>The literal 5000000000 of type int is out of range</p>
  </blockquote>
  <p>Why does the compiler by default assume the literal to be type <code>int</code> when it is declared with type <code>long</code>?</p>