This notebook introduces advanced language features in RAW, which are useful for structuring more complex RQL programs.

## Declarations¶

Declarations are used to organize RQL expressions.

Given the query:

... we can instead structure it using declarations as follows:

The queries are equivalent in terms of execution.

Each declaration can be bound to any RAW expression/query.

## Functions¶

Functions are similar to declarations, but take arguments as input:

Functions can have default arguments and can be overridden.

## Anonymous functions¶

Anonymous functions, or functions without names, can also be defined.

These use the syntax:

\(<list of arguments>) -> <body>

For instance:

Of course defining an anonymous function then binding it to the name f isn't very useful.