title: I need to know how the output was generated by this source code
body: <pre><code>#include &lt;stdio.h&gt;
  int main()
  {
      char c[]="GATE2016";
      char *p = c;
      printf("%s",p+ p[3] - p[1]);
  }
  </code></pre>
  
  <p>The output to the above source code is </p>
  
  <pre><code>2016
  </code></pre>
  
  <p>I don't have the slightest clue how that came. Also when I edit </p>
  
  <pre><code>char c[]="asdf2016"
  </code></pre>
  
  <p>the output shown is</p>
  
  <pre><code>`
  </code></pre>
  
  <p>Can anybody help me in this?</p>