title: JavaScript negative element in array
body: <p>This is my JavaScript array code for negative index number.
  In output why doesn't consider negative index number in the count of the element? It shows only count (3) in output.</p>
  
  <p><strong>Code</strong></p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>let abc = ['gnagar', 'ahmedabad', 25];
  console.log(abc, typeof(abc));
  console.log(abc[-1]);
  abc[-1] = 'abc';
  console.log(abc, typeof(abc));
  console.log(abc[-1]);</code></pre>
  </div>
  </div>
  </p>