Re: Getting elements of a list
Re: Getting elements of a list
- Subject: Re: Getting elements of a list
- From: Skeeve <email@hidden>
- Date: Sat, 19 Apr 2008 17:25:12 +0200
Mark J. Reed wrote:
Say I have a list of lists:
set myList to {{1,2},{3,4},{5,6}}
get_every(1, {{1, 2}, {3, 4}, {5, 6}})
to get_every(nth_item, of_list)
if of_list is {} then return {}
return {item nth_item of first item of of_list} &
get_every(nth_item, rest of of_list)
end get_every
good old recursion...
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden