1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-09-01 18:54:39 +02:00
This commit is contained in:
Justin Lin
2021-02-10 08:42:30 +08:00
parent f560afa901
commit f0c07f1110
3 changed files with 28 additions and 0 deletions

17
docs/lib3x-some.md Normal file
View File

@@ -0,0 +1,17 @@
# some
The `some` function tests whether at least one element in the list passes the test implemented by the provided function.
**Since:** 3.0
## Parameters
- `lt` : the list.
- `test` : a test function that accepts an element and returns `true` or `false`.
## Examples
use <util/some.scad>;
isOdd = function(elem) elem % 2 == 1;
assert(some([1, 30, 39, 29, 10, 13], isOdd));