Scope of global variables in Subroutine. (Release Announcements)
You are correct, In many languages c, javaScript, ... the variables defined outside of a function are available globally. This often leads to very sloppy code with lots of globals, in beginning programmers. The BASIC I learned kept each function/subroutine as a separate variable context (except for the ones specifically set as global). Old habits.
Jim
Complete thread:
- Scope of global variables in Subroutine. -
aprekates,
2015-06-17, 09:32
- Scope of global variables in Subroutine. -
aprekates,
2015-06-17, 09:45
- Scope of global variables in Subroutine. - Jim, 2015-10-26, 23:30
- Scope of global variables in Subroutine. -
aprekates,
2015-06-17, 09:45