FANDOM


Syntax

ASK number or list list

Explanation

ASK causes the turtles named in its first argument to execute the commands in its second argument. ASK makes it possible to send commands to a turtle that is not currently active without making it one of the active turtles.

The first argument to ask can be either a single turtle number or a list of turtle numbers. To ASK a turtle it must be defined with the SETTURTLES command.

See also EACH, TELL, TURTLES, and WHO.

Examples

Pc logo 2
? ASK 10 [ST FD 30]

Turtle 10 moves forward 30 turtle steps.

? ASK 1 \

? [SETORIGIN [50 0]

? ASK [0 1] [ST]

Pc logo 3
? ASK [0 1] \

? [REPEAT 4[FD 30 \

? FD 30 RT 90]]

?

Turtle 0 and 1 draw squares.

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.