JoeLopez wrote:So you are saying that we copy the char "" to the address of the variable,
not the name of the variable?
No, that's the "trick".
If you have one char, it can hold one(!) char, number or sign, you find on
your keyboard, e.g. a, G, %, 5.
But this variable, called text[], is an array(!) of chars, the only way to
get strings in C.
A string is simply a chain of chars, e.g. String, GE1.4, *§&?!.
In C, such string is an array of chars plus the mark for its end, i.e.
s,t,r,i,n,g,\0(there are 2 chars, but it's read as one!). Thats the reason,
why you have to declare the array at least one char larger as needed, char text[7]
in this case.
In this array, every char has its own adress, s-1, t-2, r-3 etc., up to g-6.
If you knew, how long the text array is, it would be easy, to access the
last char with text[6].
In the Backspace-code, you first have to measure the length of the string,
cut of the end mark (-1), and then replace the last char by a whitespace("").
It seems, that the easy way with text[strlen(text)-1] = 0 (or = "") does
not work in GE, so you have to use the workaround with the strcpy-function,
telling it the adress of the char, you want to overwrite.
The adress of the variable instead is the first char !
Hope I have put it right,
About the usage of text actors, I can't say anything.
Cheers !