KScript docs
EN

money[] fields and methods

A field is a plain fact about the value, read with a dot and no brackets: $value.name. A method takes arguments or does work, and is called with ->: $value->name(arguments), or with the value piped in: $value |> name(arguments).

From KScript.Core

#money[]->total() → money

Adds the amounts in list order in the first currency, using the same exchange rates and rounding as +. An empty list gives null.
Example
<let name="x" type="money[]" value="['GBP 9.50', 'GBP 0.50']" />
<echo>{ $x->total() }</echo>
$x: money[] = ['GBP 9.50', 'GBP 0.50']
echo $x->total()

Methods from any

Methods from list