title: C++ How pointer's memory address and pointed array's memory address can be same?
body: <p>In this code <code>ar</code> and <code>&amp;ar</code> same. But isn't <code>ar</code>just a constant pointer to <code>ar[0]</code>?Then I suppose writing <code>cout&lt;&lt;ar;</code> should give <code>ar[0]</code>'s memory adress while writing <code>cout&lt;&lt;&amp;ar;</code> should give it's own memory adress so they should be different. How they are same? Some say <code>ar</code> is not a pointer than how <code>cout&lt;&lt;*ar</code> is equal to <code>ar[0]</code>'s value if it is not a pointer to <code>ar[0]</code> ?</p>
  
  <pre><code>int ar[3] = {1,2,3};
  cout&lt;&lt;ar&lt;&lt;endl;
  cout&lt;&lt;&amp;ar&lt;&lt;endl;
  </code></pre>
  
  <p>I mean in this code <code>&amp;a</code> and <code>&amp;b</code> are different which makes sense. </p>
  
  <pre><code>   int a = 5;
      int* b = &amp;a;
      cout&lt;&lt;&amp;a&lt;&lt;endl;
      cout&lt;&lt;&amp;b&lt;&lt;endl;
  </code></pre>