Flatten a list: Difference between revisions
→{{header|AppleScript}}
m (→{{header|AppleScript}}: Tidying and comments.) |
|||
Line 334:
Or, to make more productive use of the language (where "efficiency" is a function of the scripter's time, rather than the machine's) we can express this in terms of a generic '''concatMap''':
{{trans|JavaScript}}
<lang AppleScript>-- flatten :: Tree a -> [a]
|