title: java.lang.IndexOutOfBoundsException: Invalid index 5, size is 5
body: <p>This error occurs sometimes and sometimes it works properly. I really can't understand what the problem is.</p>
  
  <pre><code>int length = CitiesInfos.citiesOnTheRoad.length;
  for (int i = 0; i &lt; length; i++)
  {
      HashMap&lt;String,String&gt; temp=new HashMap&lt;String, String&gt;();
      temp.put(FIRST_COLUMN, CitiesInfos.citiesOnTheRoad[i]);
  
      if (CitiesInfos.roadWorkArrayList.get(i)!=null)
      {
          temp.put(SECOND_COLUMN, CitiesInfos.weatherArrayList.get(i).getCelcius() + ", " +
                   CitiesInfos.weatherArrayList.get(i).getWeatherStatus());
      }
      else
      {
          temp.put(SECOND_COLUMN, " ");
      }
  }
  </code></pre>
  
  <p>This is the line to which logCat directs. What can the problem be?</p>