How can I combine two const char*s into a third?
i’m trying to do this with this code:
const char* pName = "Foo"
printf("\nMy name is %s.\n\n\n",pName);
const char* nName;
int num_chars = asprintf(&nName, "%s%s", "Somebody known as ", pName);
But I get this error:
'asprintf': identifier not found
I include stdio.h via this code:
#include <stdio.h>
Simple, just use C++: