AppleScript名:listをフィルターする(指定数以上の要素) |
— Created 2014-12-28 by Takaaki Naganoya — 2014 Piyomaru Software use AppleScript version "2.4" use scripting additions use framework "Foundation" set theArray to current application’s NSArray’s arrayWithArray:{8, 2, 7, 3, 9, 1, 6, 4} set thePred to current application’s NSPredicate’s predicateWithFormat:"self > 6" set bArray to (theArray’s filteredArrayUsingPredicate:thePred) as list –> {8, 7, 9} |
More from my site
(Visited 13 times, 1 visits today)