hi guys, i just want to know if static local variable consume less memory than global variable
Thanks
Printable View
hi guys, i just want to know if static local variable consume less memory than global variable
Thanks
A quote:
from Performance Tuning TipsQuote:
18. Use Module-Level Variables Instead Of "Static" Local Variables [0114]
While static variables are useful for storing values between multiple executions of a procedure, they are slower than local variables. By storing the same value in a module-level variable your procedure will execute faster. Note, however, that you will need to make sure that only one procedure is allowed to change the module-level variable. The tradeoff here is that code will be less readable and harder to maintain.
speed doesn't matter for me
my question is which one cosume less memory :)
I'm not sure but if it's faster, that means it takes less memory to run