
    .hh                     T    S r SSK7  S rS r\S:X  a  \" \" 5       5        \" 5         gg)a@  turtle-example-suite:

         tdemo_round_dance.py

(Needs version 1.1 of the turtle module that
comes with Python 3.1)

Dancing turtles have a compound shape
consisting of a series of triangles of
decreasing size.

Turtles march along a circle while rotating
pairwise in opposite direction, with one
exception. Does that breaking of symmetry
enhance the attractiveness of the example?

Press any key to stop the animation.

Technically: demonstrates use of compound
shapes, transformation of shapes as well as
cloning turtles. The animation is
controlled through update().
    )*c                      Sq g )NF)running     ?/opt/python-3.13.8/usr/lib/python3.13/turtledemo/round_dance.pystopr	      s    Gr   c                     [        5         [        S5        [        S5        [        S5        Sn SnSnSn[	        S5      n[        S	5       HD  n[        U5        [        5       nX -  nX0-  n[        U* 5        UR                  XcS
SU-
  4S5        MF     [        SU5        [        S5        [        S5        [        5         [        SS5        / n[        S5       HR  n[        S5        [        S5        [        S5        [        5         US-  S:X  d  M9  UR!                  [#        5       5        MT     [%        5         Sq[)        [*        5        [-        5         Sn[&        (       a  Sn	U H@  n
U
R                  S5        U
R                  S5        U
R                  U	5        U	S:  a  SOSn	MB     US:  a  [/        S5        [        U5        US-  n[        5         [&        (       a  M  g)Ngray10Ftriangleg}Rc?gy!"@      compound
   g      ?blackmultitrir   i8            T   gGz?zDONE!)clearscreenbgcolortracershapeShaperange	shapesizeget_shapepolytiltaddcomponentregister_shapepusetposfdltupdateappendclonehomer   
onkeypressr	   listenright)fphiscshipdancerscstadancers              r   mainr:      s   MH
5M	*
A
C	A	A	z	B2Y!?		cT

tQqS>73  :r"aL	*D
1dOG3Z
1R
1r6Q;NN57#  	FGt
H	
B
'FIIaLIIaLKKOAv1B	 
 8!HbM%KB ' r   __main__N)__doc__turtler	   r:   __name__printmainloopr   r   r   <module>rA      s7   0 3j Z	$&MJ r   