add tasks starting with a number
This commit is contained in:
parent
9246b988c7
commit
2dd7375f96
204 changed files with 3726 additions and 0 deletions
17
Task/100-doors/AppleScript/100-doors.applescript
Normal file
17
Task/100-doors/AppleScript/100-doors.applescript
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
set is_open to {}
|
||||
repeat 100 times
|
||||
set end of is_open to false
|
||||
end
|
||||
repeat with pass from 1 to 100
|
||||
repeat with door from pass to 100 by pass
|
||||
set item door of is_open to not item door of is_open
|
||||
end
|
||||
end
|
||||
set open_doors to {}
|
||||
repeat with door from 1 to 100
|
||||
if item door of is_open then
|
||||
set end of open_doors to door
|
||||
end
|
||||
end
|
||||
set text item delimiters to ", "
|
||||
display dialog "Open doors: " & open_doors
|
||||
Loading…
Add table
Add a link
Reference in a new issue