Turtle and Observer Command

count-pc color

Returns the number of patches that are the color color. Note: This command can also be executed by patches, for example within an ask-patches statement.

Related commands: