How are static variables stored in memory!!!
initialized static variables are stored in the Data segment, but in that case there will be two copies of static int i in the data segment according to the given code below, but how is it possible??..can some1 please tell me how are they stored in the memory, because this program is working fine..
Re: How are static variables stored in memory!!!
A variable name only represents a location in memory. Since each i is in a different function the compiler can tell the difference and there is no conflict. Variable storage only stores the value, not the name.
|All times are GMT +5.5. The time now is 04:47.|