Palibe (Null)
The palibe
is used to represent the absence of a value. In Duwa, palibe
is a special value that is used to indicate that a variable does not have a value.
It is similar to null
in other programming languages.
Examples
Here are some examples of how you can use the palibe
in Duwa:
Initializing a variable
Below we are initializing a variable x
of type nambala
with no value.
nambala x = palibe;
Returning a value from a function
ndondomeko palibeValue() {
// Do some work
bweza palibe;
}
Checking for a null value
nambala x = palibe;
ngati(x == palibe) {
// Do something
}