(04-24-2022, 04:31 PM)Dimster Wrote: How do you guard against the duplication of variable names - same variable name in the main v's the in the library or does it matter?
Variables in Subs and Functions are private AKA localĀ unless SHARED or CONST from the main code which make them Global. It is the beauty of Subs or Functions over GOSUBs you can use the same variable name x, y, r differently in a Sub or Function and won't change the x, y, r in main code unless you pass through arguments and change it in Sub or Function.
They, variable values, could get messed up if you pass them to a sub or function as arguments and that sub or function changes them. Be careful with that, member, Gets, just caught that happening with permanent color change help question.
b = b + ...