uce/site/doc/pages/2_StringList_each.txt
2026-06-16 12:21:31 +00:00

20 lines
440 B
Plaintext

:sig
template<typename F> void StringList::each(F f) const
:params
f : callback called with each string
return value : none
:content
Calls the callback once for each string in order. Use it when you want side effects such as building output or accumulating a separate value.
:example
StringList items = split("a,b,c", ",");
items.each([](String item) { print(item, "\n"); });
:see
>types
0_StringList
2_StringList_map
2_StringList_keys