Strings as Lists
In Sloplang, strings and lists share the same interface.
Most list operations work directly on strings. Functions like `reverse`, `where`, `distinct`, `take`, and `skip` return a new string when given a string.
Loading WASM...
You can use `chars` to explicitly split a string into a character list, but often you don't need to — the pipeline handles it.
Loading WASM...
String interpolation uses `{expr}` inside strings. Any expression works inside the braces.
Loading WASM...
Parsing utilities make it easy to extract data from text — great for Advent of Code style problems.
Loading WASM...