Null object: Difference between revisions

Content added Content deleted
m (→‎{{header|ooRexx}}: upperclass -> uppercase :-))
Line 621: Line 621:
if a[i] == .nil then say "Item" i "is missing"
if a[i] == .nil then say "Item" i "is missing"
</lang>
</lang>
Uninitialized ooRexx variables do not evaluate to .nil, but rather the character string name of the variable (all upperclass). The var() built-in function allows variable validity to be tested:
Uninitialized ooRexx variables do not evaluate to .nil, but rather the character string name of the variable (all uppercase). The var() built-in function allows variable validity to be tested:
<lang ooRexx>
<lang ooRexx>
if \var("INPUT") then say "Variable INPUT is not assigned".
if \var("INPUT") then say "Variable INPUT is not assigned".
</lang>
</lang>



=={{header|Oz}}==
=={{header|Oz}}==