1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-16 11:44:50 +02:00
This commit is contained in:
Justin Lin
2022-04-15 09:42:07 +08:00
parent 8cd1638a61
commit 4fb59ebcdb

View File

@@ -8,4 +8,8 @@
*
**/
function has(lt, elem) = search([elem], lt) != [[]];
use <bsearch.scad>;
function has(lt, elem, sorted = false) =
sorted ? bsearch(lt, elem) != -1 :
search([elem], lt) != [[]];