I found this on geeksforgeeks
char *getString()
{
char *str = "Nice test for strings";
return str;
}
int main()
{
printf("%s", getString());
getchar();
return 0;
}
Output: “Nice test for strings”
I tried searching pointer functions but its not this. If you could point me to learn how this is done. It would be nice