<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
	<id>http://digida.mgpu.ru/index.php?action=history&amp;feed=atom&amp;title=%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD%3ATurtles_commands</id>
	<title>Шаблон:Turtles commands - История изменений</title>
	<link rel="self" type="application/atom+xml" href="http://digida.mgpu.ru/index.php?action=history&amp;feed=atom&amp;title=%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD%3ATurtles_commands"/>
	<link rel="alternate" type="text/html" href="http://digida.mgpu.ru/index.php?title=%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD:Turtles_commands&amp;action=history"/>
	<updated>2026-05-01T08:37:10Z</updated>
	<subtitle>История изменений этой страницы в вики</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>http://digida.mgpu.ru/index.php?title=%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD:Turtles_commands&amp;diff=46485&amp;oldid=prev</id>
		<title>Patarakin: Новая страница: «  {| class=&quot;wikitable&quot; ! task ! realisation |- | Все turtles выполняют команду | &lt;syntaxhighlight lang=&quot;Lisp&quot; line&gt; ask turtles [ fd 1 ] &lt;/syntaxhighlight&gt; |- | Выбрать turtles по условию | &lt;syntaxhighlight lang=&quot;Lisp&quot; line&gt; ask turtles with [color = red] [ set size 2 ] &lt;/syntaxhighlight&gt; |- | Исключить текущую turtle из набора | &lt;syntaxhighlight lang=&quot;Lisp&quot; line&gt; ask turtles [ show other turtles ] &lt;...»</title>
		<link rel="alternate" type="text/html" href="http://digida.mgpu.ru/index.php?title=%D0%A8%D0%B0%D0%B1%D0%BB%D0%BE%D0%BD:Turtles_commands&amp;diff=46485&amp;oldid=prev"/>
		<updated>2026-04-23T07:02:56Z</updated>

		<summary type="html">&lt;p&gt;Новая страница: «  {| class=&amp;quot;wikitable&amp;quot; ! task ! realisation |- | Все turtles выполняют команду | &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt; ask turtles [ fd 1 ] &amp;lt;/syntaxhighlight&amp;gt; |- | Выбрать turtles по условию | &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt; ask turtles with [color = red] [ set size 2 ] &amp;lt;/syntaxhighlight&amp;gt; |- | Исключить текущую turtle из набора | &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt; ask turtles [ show other turtles ] &amp;lt;...»&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! task&lt;br /&gt;
! realisation&lt;br /&gt;
|-&lt;br /&gt;
| Все turtles выполняют команду&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ fd 1 ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Выбрать turtles по условию&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles with [color = red] [ set size 2 ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Исключить текущую turtle из набора&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show other turtles ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Turtles на текущем патче&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show turtles-here ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Другие turtles на текущем патче&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show other turtles-here ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Turtles на соседних патчах&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show turtles-on neighbors4 ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Turtles в радиусе&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show turtles in-radius 3 ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Проверить, есть ли соседи-черепахи&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ if any? other turtles in-radius 2 [ set color red ] ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Посчитать число соседей&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ set label count other turtles in-radius 2 ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Получить patch под turtle&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show patch-here ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Получить patch впереди&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show patch-ahead 1 ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Проверить, можно ли идти вперед&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ if can-move? 1 [ fd 1 ] ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Выбрать самую &amp;quot;богатую&amp;quot; turtle&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
turtles-own [energy]&lt;br /&gt;
ask max-one-of turtles [energy] [ set color yellow ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Выбрать несколько turtles по максимуму&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
turtles-own [energy]&lt;br /&gt;
ask max-n-of 5 turtles [energy] [ set shape &amp;quot;star&amp;quot; ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Случайная turtle из набора&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask one-of turtles with [color = blue] [ set color pink ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Собрать список значений turtle-переменной&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
turtles-own [energy]&lt;br /&gt;
show [energy] of turtles&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Среднее значение по turtles&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
turtles-own [energy]&lt;br /&gt;
show mean [energy] of turtles&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Сумма значений по turtles&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
turtles-own [energy]&lt;br /&gt;
show sum [energy] of turtles&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Отсортировать turtles по who&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
show sort-on [who] turtles&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Сформировать набор из разных источников&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
let selected turtle-set turtles with [color = red] turtles with [shape = &amp;quot;car&amp;quot;]&lt;br /&gt;
ask selected [ set label who ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Создать links со всеми остальными&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtle 0 [ create-links-with other turtles ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Получить все links данной turtle&lt;br /&gt;
| &amp;lt;syntaxhighlight lang=&amp;quot;Lisp&amp;quot; line&amp;gt;&lt;br /&gt;
ask turtles [ show my-links ]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Patarakin</name></author>
	</entry>
</feed>