title: joining 2 const char*s c++
body: <p>How can I combine two const char*s into a third?</p>
  
  <p>i'm trying to do this with this code:</p>
  
  <pre><code>const char* pName = "Foo"
  printf("\nMy name is %s.\n\n\n",pName);
  const char* nName;
  int num_chars = asprintf(&amp;nName, "%s%s", "Somebody known as ", pName);
  </code></pre>
  
  <p>But I get this error:</p>
  
  <pre><code>'asprintf': identifier not found
  </code></pre>
  
  <p>I include stdio.h via this code:</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  </code></pre>