I used to write programs in the android sdk for google phone. One of the android developers guide that I read says that it is more efficient to declare a const
public static const NO:String = "no";
var1 == NO;
var2 = NO;
than to do this
var1=="no";
var2="no";
For Java, when you write "no" each time, a new variable is created with the value "no" stored in it so it is more memory efficient to declare the constant. I am wondering if that is the case for action script and php as well? I am maintaining action script and php programs at work and saw a lot of strings declaration like the "no" above being used.
I am wondering if it will be worth my time to refactor these code when i have to fix the programs. I plan to leave the programs that I do not have to fix as is. Any advice or insights would be great.