For example:
This is what I tried:
#include "stdafx.h"
#include <ctype.h>
char *mystrcat(char *s1p, char *s2p);
char main(void)
{
...........................
}
char *mystrcat(char *s1p, char *s2p)
{
printf("whatever = %s%s\n", s1p, s2p);
return 0;
}
How do I make this work with the 3rd pointer and have it store p1 and p2?
Replace:
*mystrcat(string1, string2);With:
char *string3 = mystrcat(string1, string2);Also if your teacher wants char*’s instead of
You could do
To concat your strings: