a83036799 ^
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
# All and any template all(container, cond: expr): expr = block: var result = true for item in items(container): if not cond(item): result = false break result if all("mystring", {'a'..'z'}.contains): echo "works" else: echo "does not work"