title: Character array, can't get array length
body: <p>This is in Java</p>
  
  <p>I'm not sure what is wrong with the arrayName.length in my code, it doesn't work on both occasions</p>
  
  <pre><code>    for (int i = 0; i&lt;arr.length; i++)
      {
          for(int j = 0; j &lt; arr2.length; j++)
          {
  
          }
      }
  </code></pre>
  
  <p>These two arrays are char arrays and does not seem want to work with the .length method. It says that "length cannot be resolved or is not a field"</p>
  
  <p>Can someone please explain to me why this is happening</p>
  
  <p><a href="https://i.stack.imgur.com/Rx1FV.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Rx1FV.png" alt="enter image description here"></a></p>