Jump to content

Scope modifiers: Difference between revisions

m (→‎{{header|REXX}}: added a homage to Jules Verne's Nemo. -- ~~~~)
Line 271:
//can use x and y here, but NOT z
}</lang>
 
=={{header|Liberty BASIC}}==
Functions, subroutines and variables are not declared before use.
 
Single-dimensioned arrays with 0-10 elements do not need to be declared or dimensioned before use.
 
Single-dimensioned arrays with indices greater than 10 and double-dimensioned arrays must be dimensioned before use.
 
There are two types of variables: string and numeric. Variables are visible in the scope in which they appear. unless they are declared GLOBAL.
 
Global variables are visible in all scopes.
 
Local variables may be passed ByRef and then become visible inside subs and functions.
 
Some entitities are global by default. These include arrays, structs, handles and special variables such as DefaultDir$, WindowWidth, and ForegroundColor$
 
=={{header|JavaScript}}==
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.