mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-01-17 14:18:13 +01:00
17 lines
404 B
Markdown
17 lines
404 B
Markdown
# every
|
|
|
|
The `every` function tests whether all elements in the list pass 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/every.scad>
|
|
|
|
biggerThanZero = function(elem) elem > 0;
|
|
assert(every([1, 30, 39, 29, 10, 13], biggerThanZero)); |