Jump to content

Flatten a list: Difference between revisions

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]
9,659

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.