title: Java Array Index Out of Bounds Exception No matter the array length
body: <pre><code>package helloworld;
  public class windspeed {
  
      public static void main(String args[]) {
          int t = Integer.parseInt(args[44]); //this is the array input for temperature
          int v = Integer.parseInt(args[15]); //this is the array input for wind speed
          double x = Math.pow(v, 0.16); //this is the exponent math for the end of the equation
          if (t &lt; 0) {
              t = t*(-1); //this is the absolute value for temperature
          }
          double w = (35.74 + 0.6215*t)+((0.4275*t - 35.75)* x); //this is the actual calculation
          if (t&lt;=50 &amp;&amp; v&gt;3 &amp;&amp; v&lt;120) { //this is so the code runs only when the equation works
              System.out.println(w);
          }
          if (t&gt;50 || v&lt;3 || v&gt;120){
              System.out.println("The wind chill equation doesn't work with these inputs, try again.");
          }
  
      }
  }
  </code></pre>
  
  <p>This gives me an <code>ArrayIndexOutOfBounds</code> error. It doesn't matter what I put in the <code>[]</code> I get an error... why? and how can I fix it?</p>