April 27th, 2009, 12:13 PM
wait. str is getting the returning value of function2. So now the value is stored. Why it is cleared when it is printeD?
April 27th, 2009, 11:02 AM
@Lindley thanks for the code, but I do not understand what the function3 does?
@VictorN now it prints random string, but again I don't know what's the difference with the code of laserlight.
April 27th, 2009, 09:56 AM
I got error [Warning] address of local variable `text' returned.
Anyway, I got the text printed on the screen without altering the code.
btw why u use const?
April 27th, 2009, 09:36 AM
laserlight now I understand what are u saying to me. But I don't find I reason, why the code should not work. It is everything correct. It is true that after calling the function Function1 the...
April 27th, 2009, 09:18 AM
Wait are u saying to me that I return pointer which doesn't exists in the function implementation?
April 27th, 2009, 08:50 AM
Thanks for the replies.
@Speedo does the pointer points to the first element of the array? The array itself its a pointer, right?
@VictorN I don't understand why you say my Implementation is...
April 27th, 2009, 08:22 AM
Why do I need char *Function()? I mean, why do I need the * in front of the Function1() ??
Does the * mean pointer?
#include <iostream>
using namespace std;
char *Function1()
{